diff --git a/README.md b/README.md index 1472bf1..6315818 100644 --- a/README.md +++ b/README.md @@ -49,7 +49,7 @@ or start with stack followed by an integer `stack1` `a` -Immediate values can be of 9 types: +Immediate values can be of 11 types: 1. Integers as decimals: {Digits} or -{Digits} `42` @@ -57,8 +57,23 @@ Immediate values can be of 9 types: And integers as Hexadecimals:: 0x{Hexdigits} `0x0deadbeef0` -2. addresses, a base58 encoded string starting with # followed by a number of base58chars - `#nv5B93FPzRHrGNmMdTDfGdd5xGZvep3MVSpJqzcQmMp59bBCv` +2. Chain Objects. These are all addresses to different types of chain objects. + Each address is a 256 bits number encoded in base64 with a prefix. + +2a. Address: a base58 encoded number starting with @ followed by a number of base58chars + `@nv5B93FPzRHrGNmMdTDfGdd5xGZvep3MVSpJqzcQmMp59bBCv` + +2b. Contract address: ct_{base58char}+ + `ct_nv5B93FPzRHrGNmMdTDfGdd5xGZvep3MVSpJqzcQmMp59bBCv` + +2c. Oracle addresse: ok_{base58char}+ + `ok_nv5B93FPzRHrGNmMdTDfGdd5xGZvep3MVSpJqzcQmMp59bBCv` + +2d. Name addresse: nm_{base58char}+ + `nm_nv5B93FPzRHrGNmMdTDfGdd5xGZvep3MVSpJqzcQmMp59bBCv` + +2e. Channel addresse: ch_{base58char}+ + `ch_nv5B93FPzRHrGNmMdTDfGdd5xGZvep3MVSpJqzcQmMp59bBCv` 3. Boolean true or false `true` @@ -88,6 +103,13 @@ Immediate values can be of 9 types: 9. Variants: (| Size | Tag | ( Elements ) |) `(| 42 | 12 | ( "foo", 12) |)` +10. Hashes: #{base64char}+ + `#AQIDCioLFQ==` + +11. Signatures: ${base64char}+ + `$AQIDCioLFQ==` + + Where Digits: [0123456789] @@ -96,6 +118,8 @@ Hexdigits: [0123456789abcdef] base58char: [123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz] +base64char: [ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxy0123456789+/=] + Characters: any printable ascii character 0..255 (except " no quoting yet) Key: any value except for a map diff --git a/src/aeb_fate_asm.erl b/src/aeb_fate_asm.erl index aed4029..dab824c 100644 --- a/src/aeb_fate_asm.erl +++ b/src/aeb_fate_asm.erl @@ -34,7 +34,7 @@ %%% stack1 %%% a %%% -%%% Immediate values can be of 9 types: +%%% Immediate values can be of 11 types: %%% 1a. Integers as decimals: {Digits} or -{Digits} %%% 42 %%% -2374683271468723648732648736498712634876147 @@ -42,7 +42,7 @@ %%% 0x0deadbeef0 %%% 2a. addresses, a base58 encoded string prefixed with @ %%% @foo -%%% 2b. contract addresse: ct_{base58char}+ +%%% 2b. contract address: ct_{base58char}+ %%% 2c. oracle addresse: ok_{base58char}+ %%% 2d. name addresse: nm_{base58char}+ %%% 2e. channel addresse: ch_{base58char}+ @@ -67,10 +67,15 @@ %%% (1, "foo") %%% 9. Variants: (| Size | Tag | ( Elements ) |) %%% (| 42 | 12 | ( "foo", 12) |) +%%% 10. Hashes: #{base64char}+ +%%% #AQIDCioLFQ== +%%% 11. Signatures: ${base64char}+ +%%% $AQIDCioLFQ== %%% %%% Where Digits: [0123456789] %%% Hexdigits: [0123456789abcdef] %%% base58char: [123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz] +%%% base64char: [ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxy0123456789+/=] %%% Characters any printable ascii character 0..255 (except " no quoting yet) %%% Key: any value except for a map %%% Bits: 01 or space