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

SegmentAllocator:allocateArray(*) default behavior mismatch to spec

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • P3
    • 19
    • 19
    • core-libs

    Backports

      Description

        As per the spec of
        https://download.java.net/java/early_access/jdk19/docs/api/java.base/java/lang/foreign/SegmentAllocator.html#allocateArray(java.lang.foreign.ValueLayout.OfByte,byte...)

        "Implementation Requirements:
        the default implementation for this method calls this.allocateArray(layout, array.length)."

        Expectations :

        invoking SegmentAllocator:allocateArray(*) shall delegate a call to allocateArray(MemoryLayout elementLayout, long count)

        Actual :

        The method allocateArray(MemoryLayout elementLayout,
         long count) not invoked

        Attachments

          Issue Links

            Activity

              People

                mcimadamore Maurizio Cimadamore
                kganapureddy Krushnareddy Ganapureddy
                Votes:
                0 Vote for this issue
                Watchers:
                5 Start watching this issue

                Dates

                  Created:
                  Updated:
                  Resolved: