Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8217414

api/PointerTest and api/ArrayTest are vacuously passing

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: P3 P3
    • repo-panama
    • repo-panama
    • tools

      Because test methods in api/PointerTest and api/ArrayTest are not marked as `public` no tests are being run. But, jtreg shows this as a passing test result.

      Turning on the tests, both fail. For PointerTest there is a simple fix of changing the test itself. But for api/ArrayTest binder code needs to be changed in order to make it pass.

      In particular, this test relies on the creation of an out-of-bounds pointer to use as an end condition for iteration, but currently creating out-of-bounds pointers is not allowed in the binder.

      We already do a bounds check when doing memory access, so I think we can safely elide the bounds check in the BoundedPointer constructor, which would make the test pass as well

            jvernee Jorn Vernee
            jvernee Jorn Vernee
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: