Subject: Re: Values of objects
From: Tony V E (tvaneerd_at_[hidden])
Date: 2019-08-28 12:02:44
On Wed, Aug 28, 2019 at 11:35 AM Hyman Rosen <hyrosen_at_[hidden]> wrote:
> On Mon, Aug 26, 2019 at 1:53 AM Tony V E via Std-Discussion <
> std-discussion_at_[hidden]> wrote:
>> Are you then going to continue, and define what value is?
> The right way to define this is to say that objects have a value
> representation consisting
> of a fixed subset of the bits of their object representation, and that the
> value of an object
> is the sequence of bits in the value representation.
How does that interact with == ?
Typically we consider equal things to have equal values and == returns true
iff values are equal.
Consider -0 == 0, for example. And in general, a user-defined class can
have the same "value" stored with different bit representations.
-- Be seeing you, Tony
STD-DISCUSSION list run by herb.sutter at gmail.com
Older Archives on Google Groups