Chromium Code Reviews
Description[vm] Change TypedData_getUint64 native method to silently cast values
The TypedData_getUint64 native method is used to implement Uint64List
and ByteData.getUint64().
When running in --limit-ints-to-64-bits mode (with Dart integers
limited to 64 bits), this native method and its clients should
silently cast values (with wrap-around) to signed 64-bit integer.
This is the intended behavior, chosen to make it possible to work
with arbitrary data.
This CL changes underlying Integer::NewFromUint64() to do the silent
conversion instead of returning Integer::null().
Another client of Integer::NewFromUint64, Dart_NewIntegerFromUint64 is
changed to handle error without relying on Integer::NewFromUint64().
R=zra@google.com
Issue: https://github.com/dart-lang/sdk/issues/30103
Committed: https://github.com/dart-lang/sdk/commit/41fb3c6d16f1d466d4e7968c2c677c415c397d7c
Patch Set 1 #
Total comments: 6
Patch Set 2 : Added test, review fixes #
Total comments: 2
Patch Set 3 : Loop test to verify optimized mode too #
Total comments: 2
Messages
Total messages: 11 (2 generated)
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||