<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
</head>
<body>
<div class="moz-cite-prefix">Am 21.01.2023 um 14:50 schrieb
<a class="moz-txt-link-abbreviated" href="mailto:forax@univ-mlv.fr">forax@univ-mlv.fr</a>:<br>
</div>
<blockquote type="cite"
cite="mid:560816316.2755072.1674309043862.JavaMail.zimbra@u-pem.fr">
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<div style="font-family: arial, helvetica, sans-serif; font-size:
12pt; color: #000000">
<div><br>
</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>"Gernot Neppert" <a class="moz-txt-link-rfc2396E" href="mailto:mcnepp02@googlemail.com"><mcnepp02@googlemail.com></a><br>
<b>To: </b>"Valhalla Expert Group Observers"
<a class="moz-txt-link-rfc2396E" href="mailto:valhalla-spec-observers@openjdk.java.net"><valhalla-spec-observers@openjdk.java.net></a>, "Remi
Forax" <a class="moz-txt-link-rfc2396E" href="mailto:forax@univ-mlv.fr"><forax@univ-mlv.fr></a><br>
<b>Sent: </b>Saturday, January 21, 2023 12:14:50 PM<br>
<b>Subject: </b>Q-types are dead, long live non-null side
attributes<br>
</blockquote>
</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;">
<p>Hi,</p>
<p>looks like a great idea to me - which is no wonder
because I propsed it back in June 2021 already, as this
posting proves:<br>
</p>
<p><a class="moz-txt-link-freetext"
href="https://mail.openjdk.org/pipermail/valhalla-spec-observers/2021-June/001527.html"
target="_blank" moz-do-not-send="true">https://mail.openjdk.org/pipermail/valhalla-spec-observers/2021-June/001527.html</a><br
data-mce-bogus="1">
</p>
<p>In that text, I wrote something very similar to Remi's
reasoning: <br>
</p>
<pre>"do we really need to have two different type-mirrors corresponding
to these descriptors?
Isn't the "Q-ness" rather a property of the Field, method Parameter or
method return-type, and therefore should be available there via
reflection as a simple boolean property?"</pre>
</blockquote>
<div><br>
</div>
<div>Hi Gernot,<br data-mce-bogus="1">
</div>
<div>there is a subtle difference, what you are describing is
a model based on a field/method property while the proposed
model goes a step further and also defines the nullability
on types.</div>
<div><br data-mce-bogus="1">
</div>
<div>This is important because we want to be able to flatten
the array of an ArrayList<@Nullable Complex>.
Something we can not represent with only a boolean property
on fields/methods.<br data-mce-bogus="1">
</div>
<div><br data-mce-bogus="1">
</div>
<div>regards,<br data-mce-bogus="1">
</div>
<div>Rémi<br data-mce-bogus="1">
</div>
<div><br data-mce-bogus="1">
</div>
</div>
</div>
</blockquote>
<p>Of course there are subtle differences, there always are :)</p>
<p>But the common ground of both proposals - and IMO a crucial
difference to the approach that was taken in Valhalla so far - is
this:</p>
<p>Move away from burdening the type-declaration of value/primitive
classes with so many implications on its use-sites. <br>
</p>
<p>Also, do away with two different type-mirrors for primitive
classes. <br>
</p>
<p>Rather, request specific behaviour at the use-sites (parameter
declarations, return-types etc.)</p>
<p>BTW, I also proposed @Nullable (alternatively @ByRef) and its
antagonist @ByValue. I also made a propsal on the overriding issue
there:<br>
</p>
<p><a class="moz-txt-link-freetext" href="https://mail.openjdk.org/pipermail/valhalla-spec-comments/2021-November/000024.html">https://mail.openjdk.org/pipermail/valhalla-spec-comments/2021-November/000024.html</a></p>
<p>Regards,</p>
<p>Gernot<br>
</p>
<p><br>
</p>
<p><br>
</p>
</body>
</html>