[foreign-abi] [Rev 04] RFR: 8241504: Expose MemoryLayout annotations/attributes in the public API
Jorn Vernee
jvernee at openjdk.java.net
Thu Mar 26 11:24:18 UTC 2020
> Hi,
>
> This PR exposed MemoryLayout attributes in the public API.
>
> A summary of the changes:
> - Renamed annotation -> attribute everywhere to avoid confusion with Java language annotations
> - Made sure that annotations were being serialized as part of a MemoryLayout's ConstantDesc, as well as the alignment
> which was previously left out. (The latter also meant changing PaddingLayout::hasNaturalAlignment to always return
> `true`, so serializing alignment is skipped for padding). Removed special casing for the abiType attribute. This can
> now instead be handled through the generic attribute mechanism.
>
> Thanks,
> Jorn
Jorn Vernee has updated the pull request with a new target base due to a merge or a rebase. The incremental webrev
excludes the unrelated changes brought in by the merge/rebase. The pull request contains 17 additional commits since
the last revision:
- Merge branch 'Attributes' of https://github.com/JornVernee/panama-foreign into Attributes
- Don't filter by type when looking up layout attributes, and instead fail with a CCE by casting directly if the type is
incorrect, to avoid silent errors.
- Update src/jdk.incubator.foreign/share/classes/jdk/incubator/foreign/SystemABI.java
Co-Authored-By: Maurizio Cimadamore <54672762+mcimadamore at users.noreply.github.com>
- Remove ML::attribute(String, Class) helper method.
- Addressed review comments + added basic tests
- Removed trailing whitespace
- Clean up diff
- Removed abiType, added type-casting helper for attribute
- Rename annotations to attributes, and expose them in the public API.
- Merge branch 'Attributes' of https://github.com/JornVernee/panama-foreign into Attributes
- Remove ML::attribute(String, Class) helper method.
- Update src/jdk.incubator.foreign/share/classes/jdk/incubator/foreign/SystemABI.java
Co-Authored-By: Maurizio Cimadamore <54672762+mcimadamore at users.noreply.github.com>
- Addressed review comments + added basic tests
- Removed trailing whitespace
- Clean up diff
- Removed abiType, added type-casting helper for attribute
- Rename annotations to attributes, and expose them in the public API.
-------------
Changes:
- all: https://git.openjdk.java.net/panama-foreign/pull/64/files
- new: https://git.openjdk.java.net/panama-foreign/pull/64/files/d3baa351..19e5560e
Webrevs:
- full: https://webrevs.openjdk.java.net/panama-foreign/64/webrev.04
- incr: https://webrevs.openjdk.java.net/panama-foreign/64/webrev.03-04
Stats: 405 lines in 12 files changed: 392 ins; 4 del; 9 mod
Patch: https://git.openjdk.java.net/panama-foreign/pull/64.diff
Fetch: git fetch https://git.openjdk.java.net/panama-foreign pull/64/head:pull/64
PR: https://git.openjdk.java.net/panama-foreign/pull/64
More information about the panama-dev
mailing list