Integrated: 8317819: Scope should reflect lifetime of underying resource (mainline)

Maurizio Cimadamore mcimadamore at openjdk.org
Fri Oct 20 10:26:55 UTC 2023


On Fri, 13 Oct 2023 14:21:49 GMT, Maurizio Cimadamore <mcimadamore at openjdk.org> wrote:

> This PR is based on a port of: openjdk/panama-foreign#898
> 
> Some additional changes are contained in this PR:
> 
> * instead of using a different "always alive" scope for zero-length memory segments, we now use the global scope
> * the javadoc for `MemorySegment::ofArray`, `MemorySegment::ofBuffer` and `SymbolLookup::loaderLookup` is tweaked to say that the scope associated to the returned segments is an automatic scope
> * the javadoc for `MemorySegment.Scope` defines the concepts of global and automatic scope, which are then referenced in the `Arena` javadoc.

This pull request has now been integrated.

Changeset: b07da3ae
Author:    Maurizio Cimadamore <mcimadamore at openjdk.org>
URL:       https://git.openjdk.org/jdk/commit/b07da3ae15dc820d596484d51d972404fed67fb1
Stats:     269 lines in 12 files changed: 205 ins; 15 del; 49 mod

8317819: Scope should reflect lifetime of underying resource (mainline)

Reviewed-by: jvernee

-------------

PR: https://git.openjdk.org/jdk/pull/16183


More information about the core-libs-dev mailing list