You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Note: these methods should be documented as portable between compatible versions of arby and across different platforms (i.e. you can safely send output of object bytes from v0.4.0 running on macOS to v0.4.5 on Windows and get the same number value out at the other end).
To be able to do this at compile-time, requires a dynamic-size container type like that used for our _digits array in Nat. This could be reused, of course...
A neater way could be to create a proxy-object that just wraps _digits in a way that access into the proxy object is indexed to the individual bytes of the digits, without additional heap allocation. This could be a better way of doing it, really. We could even convert bytes back to object via such a technique!
We will encode/decode the value as big-endian sequences of bytes, and we will document it as such
The text was updated successfully, but these errors were encountered:
convert
Nat
object to sequence of bytesconvert sequence of bytes to
Nat
objectNote: these methods should be documented as portable between compatible versions of arby and across different platforms (i.e. you can safely send output of object bytes from v0.4.0 running on macOS to v0.4.5 on Windows and get the same number value out at the other end).
To be able to do this at compile-time, requires a dynamic-size container type like that used for our
_digits
array inNat
. This could be reused, of course..._digits
in a way that access into the proxy object is indexed to the individual bytes of the digits, without additional heap allocation. This could be a better way of doing it, really. We could even convert bytes back to object via such a technique!We will encode/decode the value as big-endian sequences of bytes, and we will document it as such
The text was updated successfully, but these errors were encountered: