Displaying 2 results from an estimated 2 matches for "other_length".
2016 Aug 29
2
invariant.load metadata semantics
Sanjoy, can you clarify this bit about JVM array lengths?
Presumably the same pointer can point to two arrays of different lengths
during a program's execution. Does this mean that you're relying on
invariant.load having function scope? That is, correctness depends on the
pointer not being reused for an array of a different length between the
first invariant load of that array length in
2016 Aug 29
2
invariant.load metadata semantics
...to lots of other stuff as well) clarifying it somewhere might
help!
-Justin
> Are you talking about cases like these:
>
> void f(array_t* a) {
> // Not sure if this is well-defined C++, but you get the picture
> int l = a->length; // invariant
> delete a;
> new(a) array_t(other_length);
> int l2 = a->length; // also invariant
> }
Yes,
On Mon, Aug 29, 2016 at 1:21 PM, Sanjoy Das <sanjoy at playingwithpointers.com>
wrote:
> Hi Justin,
>
> Justin Lebar wrote:
>> Sanjoy, can you clarify this bit about JVM array lengths?
>>
>> Presumably th...