diff options
author | Sverker Eriksson <[email protected]> | 2019-05-22 18:26:29 +0200 |
---|---|---|
committer | Sverker Eriksson <[email protected]> | 2019-05-22 18:26:29 +0200 |
commit | 09c228160d95f10a383e3495b02ac8645b497009 (patch) | |
tree | 5ff95b793b3d33cb0480cf1f41deb524a16d0ff7 | |
parent | fb165b251edd004e214f3ea842217a5860f317ac (diff) | |
parent | 2064fb7c9ff2d2eecabed0999c56614524f0c16b (diff) | |
download | otp-09c228160d95f10a383e3495b02ac8645b497009.tar.gz otp-09c228160d95f10a383e3495b02ac8645b497009.tar.bz2 otp-09c228160d95f10a383e3495b02ac8645b497009.zip |
Merge branch 'maint'
-rw-r--r-- | lib/stdlib/doc/src/binary.xml | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/lib/stdlib/doc/src/binary.xml b/lib/stdlib/doc/src/binary.xml index f3d4edd30f..fd991f258b 100644 --- a/lib/stdlib/doc/src/binary.xml +++ b/lib/stdlib/doc/src/binary.xml @@ -505,15 +505,16 @@ store(Binary, GBSet) -> <<1,1,1,1,1 ... 2> byte_size(A). 100 -3> binary:referenced_byte_size(A) +3> binary:referenced_byte_size(A). 100 -4> <<_:10/binary,B:10/binary,_/binary>> = A. +4> <<B:10/binary, C:90/binary>> = A. <<1,1,1,1,1 ... -5> byte_size(B). -10 -6> binary:referenced_byte_size(B) -100</code> - +5> {byte_size(B), binary:referenced_byte_size(B)}. +{10,10} +6> {byte_size(C), binary:referenced_byte_size(C)}. +{90,100}</code> + <p>In the above example, the small binary <c>B</c> was copied while the + larger binary <c>C</c> references binary <c>A</c>.</p> <note> <p>Binary data is shared among processes. If another process still references the larger binary, copying the part this |