<html><head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
  </head>
  <body>
    <p>Hi Remi<br>
      Yes, of course we were aware of that.<br>
      <br>
      Think of this proposal as an API-driven approach (in the style of
      ThreadLocal, ClassValue, ScopedValue, ...) which delivers more or
      less the same feature, but w/o changing the language.</p>
    <p><br>
    </p>
    <p>One thing that's attractive about the API approach is that it is
      not limited to just static fields, but it can also work for
      instance fields as well.</p>
    <p><br>
    </p>
    <p>(that said, I agree the two jeps should somehow be related/link
      to each other)</p>
    <p><br>
      Maurizio<br>
    </p>
    <p><br>
    </p>
    <div class="moz-cite-prefix">On 27/07/2023 17:09, Remi Forax wrote:<br>
    </div>
    <blockquote type="cite" cite="mid:1265545759.4350538.1690474147671.JavaMail.zimbra@univ-eiffel.fr">
      
      <div style="font-family: arial, helvetica, sans-serif; font-size:
        12pt; color: #000000">
        <div>Hello,<br data-mce-bogus="1">
        </div>
        <div>Are you aware of the lazy static final fields proposal ?<br>
        </div>
        <div>  <a href="https://bugs.openjdk.org/browse/JDK-8209964" moz-do-not-send="true" class="moz-txt-link-freetext">https://bugs.openjdk.org/browse/JDK-8209964</a><br data-mce-bogus="1">
        </div>
        <div><br data-mce-bogus="1">
        </div>
        <div>In think both proposals should be merged.<br data-mce-bogus="1">
        </div>
        <div><br data-mce-bogus="1">
        </div>
        <div>Rémi<br data-mce-bogus="1">
        </div>
        <div><br>
        </div>
        <hr id="zwchr" data-marker="__DIVIDER__">
        <div data-marker="__HEADERS__">
          <blockquote style="border-left:2px solid
#1010FF;margin-left:5px;padding-left:5px;color:#000;font-weight:normal;font-style:normal;text-decoration:none;font-family:Helvetica,Arial,sans-serif;font-size:12pt;"><b>From:
            </b>"Per-Ake Minborg" <a class="moz-txt-link-rfc2396E" href="mailto:per-ake.minborg@oracle.com"><per-ake.minborg@oracle.com></a><br>
            <b>To: </b>"leyden-dev" <a class="moz-txt-link-rfc2396E" href="mailto:leyden-dev@openjdk.org"><leyden-dev@openjdk.org></a><br>
            <b>Sent: </b>Thursday, July 27, 2023 5:52:46 PM<br>
            <b>Subject: </b>Draft JEP Announcement: "Computed
            Constants"<br>
          </blockquote>
        </div>
        <div>
          <style style="display:none;">P {margin-top:0;margin-bottom:0;}</style></div>
        <div data-marker="__QUOTED_TEXT__">
          <blockquote style="border-left:2px solid
#1010FF;margin-left:5px;padding-left:5px;color:#000;font-weight:normal;font-style:normal;text-decoration:none;font-family:Helvetica,Arial,sans-serif;font-size:12pt;">
            <div style="font-family: Calibri, Arial, Helvetica,
              sans-serif; font-size: 12pt; color: rgb(0, 0, 0);" class="elementToProof">
              <span class="x_elementToProof" style="font-size: 12pt;
                margin: 0px; background-color: rgb(255, 255, 255);"><span class="x_ContentPasted0 ContentPasted0" style="font-size: 14.6667px; margin: 0px; display:
                  inline !important; color: rgb(36, 36, 36);
                  background-color: rgb(255, 255, 255);">Hi all,</span></span></div>
            <div style="font-family: Calibri, Arial, Helvetica,
              sans-serif; font-size: 12pt; color: rgb(0, 0, 0);" class="elementToProof">
              <div class="x_elementToProof" style="font-size: 12pt;
                margin: 0px; background-color: rgb(255, 255, 255);">
                <br class="x_ContentPasted0 ContentPasted0" style="font-size: 14.6667px; color: rgb(36, 36, 36);
                  background-color: rgb(255, 255, 255);">
                <span class="x_ContentPasted0 ContentPasted0" style="font-size: 14.6667px; margin: 0px; display:
                  inline !important; color: rgb(36, 36, 36);
                  background-color: rgb(255, 255, 255);">  Maurizio and
                  I have drafted a JEP for computed constants, which are</span><br class="x_ContentPasted0 ContentPasted0" style="font-size: 14.6667px; color: rgb(36, 36, 36);
                  background-color: rgb(255, 255, 255);">
                <span class="x_ContentPasted0 ContentPasted0" style="font-size: 14.6667px; margin: 0px; display:
                  inline !important; color: rgb(36, 36, 36);
                  background-color: rgb(255, 255, 255);">  immutable
                  value holders that are initialized at most once.  They
                  offer</span><br class="x_ContentPasted0
                  ContentPasted0" style="font-size: 14.6667px; color:
                  rgb(36, 36, 36); background-color: rgb(255, 255,
                  255);">
                <span class="x_ContentPasted0 ContentPasted0" style="font-size: 14.6667px; margin: 0px; display:
                  inline !important; color: rgb(36, 36, 36);
                  background-color: rgb(255, 255, 255);">  the
                  performance and safety benefits of final fields while
                  offering</span><br class="x_ContentPasted0
                  ContentPasted0" style="font-size: 14.6667px; color:
                  rgb(36, 36, 36); background-color: rgb(255, 255,
                  255);">
                <span class="x_ContentPasted0 ContentPasted0" style="font-size: 14.6667px; margin: 0px; display:
                  inline !important; color: rgb(36, 36, 36);
                  background-color: rgb(255, 255, 255);">  greater
                  flexibility as to the timing of initialization.  In
                  the</span><br class="x_ContentPasted0 ContentPasted0" style="font-size: 14.6667px; color: rgb(36, 36, 36);
                  background-color: rgb(255, 255, 255);">
                <span class="x_ContentPasted0 ContentPasted0" style="font-size: 14.6667px; margin: 0px; display:
                  inline !important; color: rgb(36, 36, 36);
                  background-color: rgb(255, 255, 255);">  context of
                  Leyden, they could be one basis for shifting
                  computation</span><br class="x_ContentPasted0
                  ContentPasted0" style="font-size: 14.6667px; color:
                  rgb(36, 36, 36); background-color: rgb(255, 255,
                  255);">
                <span class="x_ContentPasted0 ContentPasted0" style="font-size: 14.6667px; margin: 0px; display:
                  inline !important; color: rgb(36, 36, 36);
                  background-color: rgb(255, 255, 255);">  both forward
                  and backward in time.</span><br class="x_ContentPasted0 ContentPasted0" style="font-size: 14.6667px; color: rgb(36, 36, 36);
                  background-color: rgb(255, 255, 255);">
                <br class="x_ContentPasted0 ContentPasted0" style="font-size: 14.6667px; color: rgb(36, 36, 36);
                  background-color: rgb(255, 255, 255);">
              </div>
              <div class="x_elementToProof" style="font-size: 12pt;
                margin: 0px; background-color: rgb(255, 255, 255);">
                <span class="x_ContentPasted0 ContentPasted0" style="font-size: 14.6667px; margin: 0px; display:
                  inline !important; color: rgb(36, 36, 36);
                  background-color: rgb(255, 255, 255);">  The draft is
                  here:<span class="x_ContentPasted0 ContentPasted0" style="margin:0px"> </span></span><a href="https://openjdk.org/jeps/8312611" target="_blank" rel="noopener noreferrer" class="x_ContentPasted0 ContentPasted0
                  moz-txt-link-freetext" style="font-size: 14.6667px;
                  margin: 0px; background-color: rgb(255, 255, 255);" moz-do-not-send="true">https://openjdk.org/jeps/8312611</a><br class="x_ContentPasted0 ContentPasted0" style="font-size: 14.6667px; color: rgb(36, 36, 36);
                  background-color: rgb(255, 255, 255);">
              </div>
              <div class="x_elementToProof" style="font-size: 12pt;
                margin: 0px; background-color: rgb(255, 255, 255);">
                <br class="x_ContentPasted0 ContentPasted0" style="font-size: 14.6667px; color: rgb(36, 36, 36);
                  background-color: rgb(255, 255, 255);">
                <span class="x_ContentPasted0 ContentPasted0" style="font-size: 14.6667px; margin: 0px; display:
                  inline !important; color: rgb(36, 36, 36);
                  background-color: rgb(255, 255, 255);">  Now that the
                  Leyden repo is open, I’ll publish the prototype code
                  to a</span><br class="x_ContentPasted0 ContentPasted0" style="font-size: 14.6667px; color: rgb(36, 36, 36);
                  background-color: rgb(255, 255, 255);">
                <span class="x_ContentPasted0 ContentPasted0" style="font-size: 14.6667px; margin: 0px; display:
                  inline !important; color: rgb(36, 36, 36);
                  background-color: rgb(255, 255, 255);">  new branch
                  there shortly.</span><br class="x_ContentPasted0
                  ContentPasted0" style="font-size: 14.6667px; color:
                  rgb(36, 36, 36); background-color: rgb(255, 255,
                  255);">
                <br class="x_ContentPasted0 ContentPasted0" style="font-size: 14.6667px; color: rgb(36, 36, 36);
                  background-color: rgb(255, 255, 255);">
              </div>
              <div class="x_elementToProof" style="font-size: 12pt;
                margin: 0px; background-color: rgb(255, 255, 255);">
                <span class="x_ContentPasted0 ContentPasted0" style="font-size: 14.6667px; margin: 0px; display:
                  inline !important; color: rgb(36, 36, 36);
                  background-color: rgb(255, 255, 255);">  Comments are
                  welcome!</span><br class="x_ContentPasted0
                  ContentPasted0" style="font-size: 14.6667px; color:
                  rgb(36, 36, 36); background-color: rgb(255, 255,
                  255);">
              </div>
              <div class="x_elementToProof" style="font-size: 12pt;
                margin: 0px; background-color: rgb(255, 255, 255);">
                <br class="x_ContentPasted0 ContentPasted0" style="font-size: 14.6667px; color: rgb(36, 36, 36);
                  background-color: rgb(255, 255, 255);">
                <span class="x_ContentPasted0 ContentPasted0" style="font-size: 14.6667px; margin: 0px; display:
                  inline !important; color: rgb(36, 36, 36);
                  background-color: rgb(255, 255, 255);">  Best, Per</span></div>
              <br>
            </div>
            <br>
          </blockquote>
        </div>
      </div>
    </blockquote>
  </body>
</html>