New candidate JEP: 502: Stable Values (Preview)

2025-01-22 Thread Mark Reinhold
https://openjdk.org/jeps/502 Summary: Introduce an API for stable values, which are objects that hold immutable data. Stable values are treated as constants by the JVM, enabling the same performance optimizations that are enabled by declaring a field final. Compared to final fields, howe

Re: RFR: 8311302: Implement JEP 493: Linking Run-Time Images without JMODs [v40]

2024-10-28 Thread Mark Reinhold
On Fri, 25 Oct 2024 16:29:52 GMT, Severin Gehwolf wrote: >> Please review this patch which adds a jlink mode to the JDK which doesn't >> need the packaged modules being present. A.k.a run-time image based jlink. >> Fundamentally this patch adds an option to use `jlink` even though your JDK >>

Re: RFR: 8311302: Implement JEP 493: Linking Run-Time Images without JMODs [v40]

2024-10-28 Thread Mark Reinhold
On Fri, 25 Oct 2024 19:54:37 GMT, Mandy Chung wrote: >> Severin Gehwolf has updated the pull request incrementally with five >> additional commits since the last revision: >> >> - Better handle patched modules >> >>Also add a test which ensures that module patching (if present), will >

New candidate JEP: 493: Linking Run-Time Images without JMODs

2024-10-21 Thread Mark Reinhold
https://openjdk.org/jeps/493 Summary: Reduce the size of the JDK by approximately 25% by enabling the jlink tool to create custom run-time images without using the JDK's JMOD files. This feature must be enabled when the JDK is built; it will not be enabled by default, and some JDK vendors

New candidate JEP: 485: Stream Gatherers

2024-09-02 Thread Mark Reinhold
https://openjdk.org/jeps/485 Summary: Enhance the Stream API to support custom intermediate operations. This will allow stream pipelines to transform data in ways that are not easily achievable with the existing built-in intermediate operations. - Mark

New candidate JEP: 484: Class-File API

2024-08-27 Thread Mark Reinhold
https://openjdk.org/jeps/484 Summary: Provide a standard API for parsing, generating, and transforming Java class files. - Mark

Integrated: 8338611: java.lang.module specification wording not aligned with JEP 261

2024-08-20 Thread Mark Reinhold
On Mon, 19 Aug 2024 21:19:13 GMT, Mark Reinhold wrote: > The `java.lang.module` package specification defines the default set of root > modules as “every module that is observable on the upgrade module path or > among the system modules, and that exports at least one packag

RFR: 8338611: java.lang.module specification wording not aligned with JEP 261

2024-08-19 Thread Mark Reinhold
The `java.lang.module` package specification defines the default set of root modules as “every module that is observable on the upgrade module path or among the system modules, and that exports at least one package without qualification.” There’s no need to use the term “observable” here, since

New candidate JEP: 473: Stream Gatherers (Second Preview)

2024-04-05 Thread Mark Reinhold
https://openjdk.org/jeps/473 Summary: Enhance the Stream API to support custom intermediate operations. This will allow stream pipelines to transform data in ways that are not easily achievable with the existing built-in intermediate operations. This is a preview API. - Mark

New candidate JEP: 466: Class-File API (Second Preview)

2024-02-15 Thread Mark Reinhold
https://openjdk.org/jeps/466 Summary: Provide a standard API for parsing, generating, and transforming Java class files. This is a preview API. - Mark

New candidate JEP: 461: Stream Gatherers (Preview)

2023-10-26 Thread Mark Reinhold
https://openjdk.org/jeps/461 Summary: Enhance the Stream API to support custom intermediate operations. This will allow stream pipelines to transform data in ways that are not easily achievable with the existing built-in intermediate operations. This is a preview API. - Mark

Re: RFR: 8318027: Support alternative name to jdk.internal.vm.compiler [v3]

2023-10-20 Thread Mark Reinhold
On Fri, 20 Oct 2023 15:45:50 GMT, Doug Simon wrote: >> The Graal code base has >> [renamed](https://github.com/oracle/graal/commit/1e41203d10db321f86723eac90f6cd0573b08b33) >> its module to `jdk.compiler.graal` as part of preparations for Project >> Galahad. Due to the way Java modules work, t

Re: RFR: 8318027: Support alternative name to jdk.internal.vm.compiler [v2]

2023-10-20 Thread Mark Reinhold
On Fri, 20 Oct 2023 15:32:55 GMT, Doug Simon wrote: >> The Graal code base has >> [renamed](https://github.com/oracle/graal/commit/1e41203d10db321f86723eac90f6cd0573b08b33) >> its module to `jdk.compiler.graal` as part of preparations for Project >> Galahad. Due to the way Java modules work, t

Re: Adding appendHex method to StringBuilder

2023-10-02 Thread Mark Reinhold
2023/10/2 10:01:10 -0400, shaojin.we...@alibaba-inc.com: > StringTemplate is great and I wish I can submit PR to improve it. But > I still think StringBuilder.appendHex is a basic API, not a formatted > API. Just like Integer.toHexString and Long.toHexString, they are very > commonly used and shoul

Re: Adding appendHex method to StringBuilder

2023-10-02 Thread Mark Reinhold
2023/10/2 7:22:55 -0400, claes.redes...@oracle.com: > I think this goes against the grain: StringBuilder is a simple builder > for non-localized unformatted output. For formatted output there’s > Formatter, String.format and, with JEP 430[1], FMT."..." to help output > string data in more advanced,

Re: RFR: 8314738: Remove all occurrences of and support for @revised

2023-08-22 Thread Mark Reinhold
On Tue, 22 Aug 2023 08:42:32 GMT, Pavel Rappo wrote: > Please review this simple PR. You can leave the copyright years as-is. - PR Comment: https://git.openjdk.org/jdk/pull/15382#issuecomment-1688104170

Re: RFR: 8314738: Remove all occurrences of and support for @revised

2023-08-22 Thread Mark Reinhold
On Tue, 22 Aug 2023 08:42:32 GMT, Pavel Rappo wrote: > Please review this simple PR. Removing `@revised` tags is not a substantive change, so I wouldn’t update the copyright year as you have in some of these files. Otherwise, this looks fine. - Marked as reviewed by mr (Lead). P

Re: RFR: 8294962: java.base jdk.internal.module package uses ASM to modify and write module-info.class

2023-03-09 Thread Mark Reinhold
On Fri, 25 Nov 2022 14:38:55 GMT, Adam Sotona wrote: > 8294962: java.base jdk.internal.module package uses ASM to modify and write > module-info.class. > This patch converts it to use Classfile API. > > Please review. > Thanks, > Adam Wouldn’t “Convert java.base/jdk.internal.module to use the

New candidate JEP: 431: Sequenced Collections

2022-10-11 Thread Mark Reinhold
https://openjdk.org/jeps/431 Summary: Introduce new interfaces to represent collections with a defined encounter order. Each such collection has a well-defined first element, second element, and so forth, up to the last element. It also provides uniform APIs for accessing its first and las

Re: RFR: 8293499: Provide jmod compression level option

2022-09-12 Thread Mark Reinhold
On Mon, 12 Sep 2022 11:48:50 GMT, Claes Redestad wrote: > > Meaning, we allow `--compress=zip-[0..9]` and default to `zip-6`. This has > > the added benefit of clearly stating that `zip-0` is still ZIP, but without > > the compression applied. This is a bit ambiguous with > > `--compression-le

Re: RFR: 8282648: Weaken the InflaterInputStream specification in order to allow faster Zip implementations [v12]

2022-08-29 Thread Mark Reinhold
On Mon, 29 Aug 2022 11:58:15 GMT, Volker Simonis wrote: >> Add an API note to `InflaterInputStream::read(byte[] b, int off, int len)` >> to highlight that it might write more bytes than the returned number of >> inflated bytes into the buffer `b`. >> >> The superclass `java.io.InputStream` sp

Re: RFR: 8282648: Weaken the InflaterInputStream specification in order to allow faster Zip implementations [v11]

2022-08-25 Thread Mark Reinhold
On Wed, 27 Jul 2022 10:47:44 GMT, Volker Simonis wrote: >> Add an API note to `InflaterInputStream::read(byte[] b, int off, int len)` >> to highlight that it might write more bytes than the returned number of >> inflated bytes into the buffer `b`. >> >> The superclass `java.io.InputStream` sp

[jdk19] Integrated: 8291512: Snippetize modules API examples

2022-07-28 Thread Mark Reinhold
On Thu, 28 Jul 2022 17:41:31 GMT, Mark Reinhold wrote: > The specification of the modules API contains several non-normative code > examples. We should convert them to use snippets, per [JEP > 413](https://openjdk.org/jeps/413). This pull request has now been integrated. Changeset:

Re: [jdk19] RFR: 8291512: Snippetize modules API examples [v2]

2022-07-28 Thread Mark Reinhold
On Thu, 28 Jul 2022 17:54:33 GMT, Joe Darcy wrote: > Looks fine; may want to change this issue to be a subtask of JDK-8289774. Thanks. Converted to subtask. - PR: https://git.openjdk.org/jdk19/pull/156

Re: [jdk19] RFR: 8291512: Snippetize modules API examples [v2]

2022-07-28 Thread Mark Reinhold
> The specification of the modules API contains several non-normative code > examples. We should convert them to use snippets, per [JEP > 413](https://openjdk.org/jeps/413). Mark Reinhold has updated the pull request incrementally with one additional commit since the last revisio

[jdk19] RFR: 8291512: Snippetize modules API examples

2022-07-28 Thread Mark Reinhold
The specification of the modules API contains several non-normative code examples. We should convert them to use snippets, per [JEP 413](https://openjdk.org/jeps/413). - Commit messages: - 8291512: Snippetize modules API examples Changes: https://git.openjdk.org/jdk19/pull/156/fil

Re: RFR: 8290824: Use InputStream.readAllBytes() instead of surrogate code

2022-07-21 Thread Mark Reinhold
On Thu, 21 Jul 2022 15:37:40 GMT, Сергей Цыпанов wrote: > We can use `InputStream.readAllBytes()` in `ModuleHashes` and `X509CertPath`. If by “surrogates” you mean “substitutes”, then this wording is confusing. At the time these explicit loops were written they weren’t surrogates for anything,

Re: RFR: 8282648: Problems due to conflicting specification of Inflater::inflate(..) and InflaterInputStream::read(..) [v10]

2022-07-21 Thread Mark Reinhold
On Mon, 9 May 2022 09:56:19 GMT, Volker Simonis wrote: >> Add an API note to `InflaterInputStream::read(byte[] b, int off, int len)` >> to highlight that it might write more bytes than the returned number of >> inflated bytes into the buffer `b`. >> >> The superclass `java.io.InputStream` spe

Re: RFR: 8290824: Use InputStream.readAllBytes() instead of surrogate code

2022-07-21 Thread Mark Reinhold
On Thu, 21 Jul 2022 15:37:40 GMT, Сергей Цыпанов wrote: > We can use `InputStream.readAllBytes()` in `ModuleHashes` and `X509CertPath`. Why do you say “instead of surrogate code”? I don’t see any Unicode surrogate processing here, but maybe you mean something else. Would “instead of explicit l

Re: RFR: 8290353: ModuleReader::list specification should suggest closing the returned stream [v3]

2022-07-19 Thread Mark Reinhold
On Tue, 19 Jul 2022 14:06:52 GMT, Ryan Ernst wrote: >> This commit adds additional clarification to the javadocs of >> ModuleReader::list about needing to close the stream. The new wording is >> similar to that used in Files::find and other similar methods. > > Ryan Ernst has updated the pull req

Re: RFR: 8290353: Clarify the streams returned by ModuleReader::list [v2]

2022-07-18 Thread Mark Reinhold
On Mon, 18 Jul 2022 18:19:48 GMT, Ryan Ernst wrote: >> This commit adds additional clarification to the javadocs of >> ModuleReader::list about needing to close the stream. The new wording is >> similar to that used in Files::find and other similar methods. > > Ryan Ernst has updated the pull req