<html xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=Windows-1252">
<meta name="Generator" content="Microsoft Word 15 (filtered medium)">
<style><!--
/* Font Definitions */
@font-face
        {font-family:"Cambria Math";
        panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0cm;
        font-size:11.0pt;
        font-family:"Calibri",sans-serif;}
.MsoChpDefault
        {mso-style-type:export-only;}
@page WordSection1
        {size:612.0pt 792.0pt;
        margin:70.85pt 70.85pt 70.85pt 70.85pt;}
div.WordSection1
        {page:WordSection1;}
--></style>
</head>
<body lang="NL-BE" link="blue" vlink="#954F72" style="word-wrap:break-word">
<div class="WordSection1">
<p class="MsoNormal"><span lang="EN-GB">On Wed Jul 13 20:54:43 UTC 2022, John Rose wrote:
<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB">> I’m using a more neutral term "realize" instead of "instantiate".<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB">I'm not really a fan of the term, I see why "instantiate" doesn't fit, but I hope stuff will be able to get reworded in such a way that "realize" isn't needed.<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB">> These propositions seem to be all true (“at least” in part):<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB">> - The result of realizing at least some classes in some types is, in fact, an "object".<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB">> - The result of realizing at least some classes in some types is, in fact, an "instance" of that class.<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB">> - The result of realizing at least some classes in a value type is a "value" of that class.<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB">> - Every variable "has a value".<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB">> - Every reference, other than `null`, "refers to an object".<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB">> - Every non-reference variable “contains a value” (as well as having it).<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB">I'm very confused what you mean with your last point. "Every non-reference variable “contains a value” (as well as having it)". A variable is a typed storage location, a variable containing a value or a variable having
 a value are in my mind synonyms. But if I read your point, it sounds like you disagree and a non-reference (primitive?) variable has and contains 2 (different?) values?<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB">---<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB">On Thu Jul 14 16:48:00 UTC 2022, Kevin Bourrillion wrote:<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB">> The instances of a value type are "values".<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB">> The instances of a reference type are "references to objects".<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB">> [...]<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB">> But primitive values are instances too. Of primitive types. I think that has always been true (though most of us aren't in the habit of saying it, because they were never *class instances* which is a very useful kind).<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB">Oh god, no no no no no nooo. The instances of a reference type are the objects, not the references to those objects. The references are the values that a variable of a compatible type can hold. And no one calls primitive
 values instances, is cause they aren't. All mentions of "instances" in Java spec refer to "class instances" or "instances of a/the class" (at least as far I can see).<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB">> An object                      | A value<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB">> -----------------------------  | -----------------------------------------<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB">> has independent existence      | is ephemeral (no existence of its *own*)<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB">> is self-describing             | is context-described<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB">> is accessed via reference      | is used directly<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB">> is eligible to have identity   | can’t have identity<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB">> is polymorphic                 | is strictly monomorphic<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB">> has the type `Object`          | does not have the type `Object`<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB">I agree with some of these but I have a few issues:<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB">* I feel like independent existence and identity are the same thing, how would you be able to differentiate 2 equal objects that don't have identity?<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB">* I think I understand what you mean with "self-describing", if I have an object, I expect to be able to call `.getClass`. As a result an object holds all the info to fully interpret the object. But I'm missing something
 with "context-described". It feels like you are saying a value needs a context to "exist", but values are ephemeral. They just exist.<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB">In the end, I don't think "object" and "value" are mutually exclusive. Anything that extends Object is an "object", anything that is ephemeral is a "value" and anything that is both is a "value object" (identityless object)<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB">> I would say that arrays are also instances -- of array types. What they aren't is *class* instances. (So they don't get to have members; `length` and `clone` are at best half-heartedly-simulated members.)<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB">Arrays do have members, all the methods of `Object` are inherited by arrays, `clone` being one of them.
<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB">---<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB">John: <o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB">> Even if we give up on making everything an object, I will still request that we cling to *some* word that can uniformly be applied to the result of realizing *any Java class*. If that word is not "object" I think it
 is "instance".<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB">Kevin:<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB">> Yes, I think it is absolutely and usefully "instance".<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB">> A tough spot about my model (which I think is unavoidable/acceptable) is that I can't get away with saying "An object is any class instance or array" anymore.<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB">Yeah this a bit of a nuisance. It would be nice to have a term that covers both "values" and "instances", because in my mind, and instance is something that gets instantiated. Ephemeral values don't get instantiated,
 cause they exist. Which means with my view objects of value classes aren't instances (?? this surprised me, but I can't convince myself otherwise anymore).<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB">Regards<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-GB">Robbe Pincket</span><span lang="EN-GB"><o:p></o:p></span></p>
</div>
</body>
</html>