<div dir="ltr"><div dir="ltr">Em dom., 17 de set. de 2023 às 17:08, Remi Forax <<a href="mailto:forax@univ-mlv.fr">forax@univ-mlv.fr</a>> escreveu:<br></div><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div><div style="font-family:arial,helvetica,sans-serif;font-size:12pt;color:rgb(0,0,0)"><div></div><div><blockquote style="border-left:2px solid rgb(16,16,255);margin-left:5px;padding-left:5px;color:rgb(0,0,0);font-weight:normal;font-style:normal;text-decoration:none;font-family:Helvetica,Arial,sans-serif;font-size:12pt"><b>From: </b>"Arne Styve" <<a href="mailto:arne.styve@ntnu.no" target="_blank">arne.styve@ntnu.no</a>><br><b>To: </b>"amber-dev" <<a href="mailto:amber-dev@openjdk.org" target="_blank">amber-dev@openjdk.org</a>><br><b>Sent: </b>Friday, September 15, 2023 5:08:04 PM<br><b>Subject: </b>JEP 445: Unnamed Classes and Instance Main Methods - don not move forward!<br></blockquote></div><div></div><div><blockquote style="border-left:2px solid rgb(16,16,255);margin-left:5px;padding-left:5px;color:rgb(0,0,0);font-weight:normal;font-style:normal;text-decoration:none;font-family:Helvetica,Arial,sans-serif;font-size:12pt">
<div>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11pt"></span></p></div></blockquote><div></div></div></div></div></blockquote><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div><div style="font-family:arial,helvetica,sans-serif;font-size:12pt;color:rgb(0,0,0)"><div><div>This JEP is really about Java enboarding, i.e. how it is easy to use Java in the small.<br></div><div></div></div></div></div></blockquote><div><br></div><div>(...)</div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div><div style="font-family:arial,helvetica,sans-serif;font-size:12pt;color:rgb(0,0,0)"><div><div>Having an unnamed class is not only important for teaching, it's also important for scripting. Scripting in Java is great and not so great at the same time. It's great because the script will work the same way on all major platforms even Windows and not so great because there is the unecessary ceremony of creating a class when what you really want is write a small script.<br></div><div>I think that people should be albe to write their scripts in Java. That why we have added the support of shebang in JEP 330. That's why there is a JEP in draft to allow to split a script into several files [1]. And that's why there is this JEP, that simplify the creation of scripts.</div></div></div></div></blockquote><div><br></div><div><br></div><div>This is the kind of benefit I envision for my team. We frequently do small tools, Picocli based, where a single class is enough. In the definition of these tools, packages and classes, public vs. private, static vs. instance, are distractions to my junior team of maintainers. I expect to move the practice of small tools to the new syntax as soon as we upgrade the runtime in each case.</div></div><div><br></div><span class="gmail_signature_prefix">-- </span><br><div dir="ltr" class="gmail_signature"><div dir="ltr"><div>Pedro Lamarão</div></div></div></div>