On Wed, 12 Jan 2022 19:05:30 GMT, Maurizio Cimadamore <mcimadam...@openjdk.org> wrote:
>> src/jdk.incubator.foreign/share/classes/jdk/internal/foreign/HeapMemorySegmentImpl.java >> line 89: >> >>> 87: public static class OfByte extends HeapMemorySegmentImpl { >>> 88: >>> 89: OfByte(long offset, Object base, long length, int mask) { >> >> Is it possible to retain the array type for the constructor? > > yes, that should be harmless Actually, no, sorry. If I sharpen the type, then `dup` has to cast, so we go back to the original issue. ------------- PR: https://git.openjdk.java.net/jdk18/pull/97