<!DOCTYPE html><html><head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
  </head>
  <body>
    <font size="4" face="monospace">One thing to be clear on about this
      effort is: this is not about lobbying for the priority of "my
      favorite feature"; this is merely about capturing explanations
      that have been previously shared, so others can find them more
      easily.  <br>
      <br>
      One aspect of moral hazard here is that it is a natural tendency
      to browse this archive and then barge into the list with "But I
      don't agree with your arguments on feature #7."  But the goal here
      is to reduce redundant "why don't you" requests, not increase it. 
      Framing the purpose of this artifact clearly can help manage
      this.  <br>
    </font><br>
    <br>
    <div class="moz-cite-prefix">On 12/12/2024 1:34 PM, Archie Cobbs
      wrote:<br>
    </div>
    <blockquote type="cite" cite="mid:CANSoFxvU1CvF32PNo=frnE0oarn9tmr_B+o+YqVk0UoZ6tDw6g@mail.gmail.com">
      
      <div dir="ltr">
        <div class="gmail_quote gmail_quote_container">
          <div dir="ltr" class="gmail_attr">On Thu, Dec 12, 2024 at
            10:07 AM Brian Goetz <<a href="mailto:brian.goetz@oracle.com" moz-do-not-send="true" class="moz-txt-link-freetext">brian.goetz@oracle.com</a>>
            wrote:<br>
          </div>
          <blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
            <div> <font size="4" face="monospace">There is the
                amber-docs repo which gets published to `<a href="http://openjdk.org/projects/amber" target="_blank" moz-do-not-send="true">openjdk.org/projects/amber`</a>,
                which is probably a better place to put it, and people
                can contribute via PRs.<br>
              </font></div>
          </blockquote>
          <div><br>
          </div>
          <div>
            <div dir="ltr">
              <div>I think putting something online under amber-docs is
                a great idea - especially the part where people can
                contribute using PR's, which fosters decentralized
                collaboration on the maintenance of the list.<br>
              </div>
              <div><br>
              </div>
              <div>While it would be ideal to have a complete directory
                of ideas with accompanying summaries of all that has
                been discussed, we should probably start with something
                simpler and more maintainable.<br>
              </div>
              <div><br>
              </div>
              <div>Here's a proposal: Have a list of "previously
                discussed ideas". Each idea has a one line description,
                a one paragraph summary, an optional example, and a
                bullet-point list of one or more links to the thread(s)
                in the archive that contain all the gory details of the
                discussion.</div>
              <div><br>
              </div>
              <div>Here's a simple example...</div>
              <div style="margin-left:40px"><br>
              </div>
              <div style="margin-left:40px"><b>Idea:</b> Using switch
                statements for if/else control flow</div>
              <div style="margin-left:40px"><br>
              </div>
              <div style="margin-left:40px"><b>Description:</b> Support
                "switches on nothing" where the cases simply provide the
                conditions on which to execute various code branches.</div>
              <div style="margin-left:40px"><br>
              </div>
              <div style="margin-left:40px"><b>Example:</b></div>
              <div style="margin-left:40px"><br>
              </div>
              <div style="margin-left:40px">    public double
                toInches(String value) {</div>
              <div style="margin-left:40px">        switch {</div>
              <div style="margin-left:40px">        case when
                value.endsWith("mm") -> return 0.0393701 *
                Integer.parseInt(value.substring(0, value.length() -
                2));</div>
              <div style="margin-left:40px">
                <div>        case when value.endsWith("ft") -> return
                  12 * Integer.parseInt(value.substring(0,
                  value.length() - 2));</div>
                <div>        case when value.endsWith("light-years")
                  -> return 3.725e+17 *
                  Integer.parseInt(value.substring(0, value.length() -
                  2));</div>
                <div>        default -> throw new
                  IllegalArgumentException("can't parse value");<br>
                </div>
              </div>
              <div style="margin-left:40px">        }<br>
              </div>
              <div style="margin-left:40px">    }</div>
              <div style="margin-left:40px"><br>
              </div>
              <div style="margin-left:40px"><b>Discussion:</b></div>
              <div style="margin-left:40px">
                <ul>
                  <li><a href="https://mail.openjdk.org/pipermail/amber-dev/2024-October/008939.html" moz-do-not-send="true" class="moz-txt-link-freetext">https://mail.openjdk.org/pipermail/amber-dev/2024-October/008939.html</a></li>
                </ul>
              </div>
              <div><br>
              </div>
              <div>Just now seeing Eirik's reference to Project Jigsaw's
                Issue Summary document. I like this even better but
                someone would have to step up and take ownership.<br>
              </div>
              <div><br>
              </div>
              <div>-Archie</div>
              <div><br>
              </div>
            </div>
          </div>
        </div>
        <span class="gmail_signature_prefix">-- </span><br>
        <div dir="ltr" class="gmail_signature">Archie L. Cobbs<br>
        </div>
      </div>
    </blockquote>
    <br>
  </body>
</html>