Re: RFR: 8318324: Drop redundant default methods from FFM API [v2]

2023-10-18 Thread Jorn Vernee
On Wed, 18 Oct 2023 13:53:35 GMT, Maurizio Cimadamore wrote: >> This PR moves turns default methods in `MemorySegment` and `MemoryLayout` >> into ordinary abstract methods. >> These interfaces cannot be subclasses by developers (they are sealed), so >> there is no reson for having default meth

Re: RFR: 8318324: Drop redundant default methods from FFM API [v2]

2023-10-18 Thread Maurizio Cimadamore
> This PR moves turns default methods in `MemorySegment` and `MemoryLayout` > into ordinary abstract methods. > These interfaces cannot be subclasses by developers (they are sealed), so > there is no reson for having default methods there. Also, default methods can > have some detrimental effect

Re: RFR: 8318324: Drop redundant default methods from FFM API

2023-10-18 Thread Jorn Vernee
On Wed, 18 Oct 2023 12:09:28 GMT, Maurizio Cimadamore wrote: >> src/java.base/share/classes/jdk/internal/foreign/layout/AbstractLayout.java >> line 47: >> >>> 45: import java.util.Optional; >>> 46: import java.util.Set; >>> 47: import java.util.function.Function; >> >> There are quite a few n

Re: RFR: 8318324: Drop redundant default methods from FFM API

2023-10-18 Thread Maurizio Cimadamore
On Wed, 18 Oct 2023 04:06:17 GMT, Jorn Vernee wrote: >> This PR moves turns default methods in `MemorySegment` and `MemoryLayout` >> into ordinary abstract methods. >> These interfaces cannot be subclasses by developers (they are sealed), so >> there is no reson for having default methods there

RFR: 8318324: Drop redundant default methods from FFM API

2023-10-18 Thread Maurizio Cimadamore
This PR moves turns default methods in `MemorySegment` and `MemoryLayout` into ordinary abstract methods. These interfaces cannot be subclasses by developers (they are sealed), so there is no reson for having default methods there. Also, default methods can have some detrimental effects, as they

Re: RFR: 8318324: Drop redundant default methods from FFM API

2023-10-18 Thread Jorn Vernee
On Tue, 17 Oct 2023 17:31:30 GMT, Maurizio Cimadamore wrote: > This PR moves turns default methods in `MemorySegment` and `MemoryLayout` > into ordinary abstract methods. > These interfaces cannot be subclasses by developers (they are sealed), so > there is no reson for having default methods