diff options
author | Kartik Agaram <vc@akkartik.com> | 2020-01-12 12:11:15 -0800 |
---|---|---|
committer | Kartik Agaram <vc@akkartik.com> | 2020-01-12 14:49:35 -0800 |
commit | f1eade728695ed3f52ae4e13f0a91dfe769e8567 (patch) | |
tree | d43079a8127487ecf9837600961f333e41ab7320 /067parse-hex.subx | |
parent | e064f1bbfdbd4386d752fbb750bf36d91dce413b (diff) | |
download | mu-f1eade728695ed3f52ae4e13f0a91dfe769e8567.tar.gz |
5883 - drop the `ref` keyword
When I created it I was conflating two things: a) needing to refer to just the start, rather than the whole, and b) counting indirections. Both are kinda ill-posed. Now Mu will have just `addr` and `handle` types. Normal types will translate implicitly to `addr` types, while `handle` will always require explicit handling.
Diffstat (limited to '067parse-hex.subx')
-rw-r--r-- | 067parse-hex.subx | 28 |
1 files changed, 14 insertions, 14 deletions
diff --git a/067parse-hex.subx b/067parse-hex.subx index b1c5e7a0..6573b358 100644 --- a/067parse-hex.subx +++ b/067parse-hex.subx @@ -93,7 +93,7 @@ test-is-hex-int: 8b/copy 0/mod/indirect 0/rm32/eax . . . 1/r32/ecx . . # copy *eax to ecx 8d/copy-address 1/mod/*+disp8 4/rm32/sib 0/base/eax 1/index/ecx . 1/r32/ecx 4/disp8 . # copy eax+ecx+4 to ecx 05/add-to-eax 4/imm32 - # var slice/ecx : (ref slice) = {eax, ecx} + # var slice/ecx : slice = {eax, ecx} 51/push-ecx 50/push-eax 89/copy 3/mod/direct 1/rm32/ecx . . . 4/r32/esp . . # copy esp to ecx @@ -127,7 +127,7 @@ test-is-hex-int-handles-letters: 8b/copy 0/mod/indirect 0/rm32/eax . . . 1/r32/ecx . . # copy *eax to ecx 8d/copy-address 1/mod/*+disp8 4/rm32/sib 0/base/eax 1/index/ecx . 1/r32/ecx 4/disp8 . # copy eax+ecx+4 to ecx 05/add-to-eax 4/imm32 - # var slice/ecx : (ref slice) = {eax, ecx} + # var slice/ecx : slice = {eax, ecx} 51/push-ecx 50/push-eax 89/copy 3/mod/direct 1/rm32/ecx . . . 4/r32/esp . . # copy esp to ecx @@ -161,7 +161,7 @@ test-is-hex-int-with-trailing-char: 8b/copy 0/mod/indirect 0/rm32/eax . . . 1/r32/ecx . . # copy *eax to ecx 8d/copy-address 1/mod/*+disp8 4/rm32/sib 0/base/eax 1/index/ecx . 1/r32/ecx 4/disp8 . # copy eax+ecx+4 to ecx 05/add-to-eax 4/imm32 - # var slice/ecx : (ref slice) = {eax, ecx} + # var slice/ecx : slice = {eax, ecx} 51/push-ecx 50/push-eax 89/copy 3/mod/direct 1/rm32/ecx . . . 4/r32/esp . . # copy esp to ecx @@ -195,7 +195,7 @@ test-is-hex-int-with-leading-char: 8b/copy 0/mod/indirect 0/rm32/eax . . . 1/r32/ecx . . # copy *eax to ecx 8d/copy-address 1/mod/*+disp8 4/rm32/sib 0/base/eax 1/index/ecx . 1/r32/ecx 4/disp8 . # copy eax+ecx+4 to ecx 05/add-to-eax 4/imm32 - # var slice/ecx : (ref slice) = {eax, ecx} + # var slice/ecx : slice = {eax, ecx} 51/push-ecx 50/push-eax 89/copy 3/mod/direct 1/rm32/ecx . . . 4/r32/esp . . # copy esp to ecx @@ -224,7 +224,7 @@ test-is-hex-int-empty: # . prologue 55/push-ebp 89/copy 3/mod/direct 5/rm32/ebp . . . 4/r32/esp . . # copy esp to ebp - # var slice/ecx : (ref slice) = "" + # var slice/ecx : slice = "" 68/push 0/imm32 68/push 0/imm32 89/copy 3/mod/direct 1/rm32/ecx . . . 4/r32/esp . . # copy esp to ecx @@ -258,7 +258,7 @@ test-is-hex-int-handles-0x-prefix: 8b/copy 0/mod/indirect 0/rm32/eax . . . 1/r32/ecx . . # copy *eax to ecx 8d/copy-address 1/mod/*+disp8 4/rm32/sib 0/base/eax 1/index/ecx . 1/r32/ecx 4/disp8 . # copy eax+ecx+4 to ecx 05/add-to-eax 4/imm32 - # var slice/ecx : (ref slice) = {eax, ecx} + # var slice/ecx : slice = {eax, ecx} 51/push-ecx 50/push-eax 89/copy 3/mod/direct 1/rm32/ecx . . . 4/r32/esp . . # copy esp to ecx @@ -292,7 +292,7 @@ test-is-hex-int-handles-negative: 8b/copy 0/mod/indirect 0/rm32/eax . . . 1/r32/ecx . . # copy *eax to ecx 8d/copy-address 1/mod/*+disp8 4/rm32/sib 0/base/eax 1/index/ecx . 1/r32/ecx 4/disp8 . # copy eax+ecx+4 to ecx 05/add-to-eax 4/imm32 - # var slice/ecx : (ref slice) = {eax, ecx} + # var slice/ecx : slice = {eax, ecx} 51/push-ecx 50/push-eax 89/copy 3/mod/direct 1/rm32/ecx . . . 4/r32/esp . . # copy esp to ecx @@ -326,7 +326,7 @@ test-is-hex-int-handles-negative-0x-prefix: 8b/copy 0/mod/indirect 0/rm32/eax . . . 1/r32/ecx . . # copy *eax to ecx 8d/copy-address 1/mod/*+disp8 4/rm32/sib 0/base/eax 1/index/ecx . 1/r32/ecx 4/disp8 . # copy eax+ecx+4 to ecx 05/add-to-eax 4/imm32 - # var slice/ecx : (ref slice) = {eax, ecx} + # var slice/ecx : slice = {eax, ecx} 51/push-ecx 50/push-eax 89/copy 3/mod/direct 1/rm32/ecx . . . 4/r32/esp . . # copy esp to ecx @@ -442,7 +442,7 @@ test-parse-hex-int-single-digit: 8b/copy 0/mod/indirect 0/rm32/eax . . . 1/r32/ecx . . # copy *eax to ecx 8d/copy-address 1/mod/*+disp8 4/rm32/sib 0/base/eax 1/index/ecx . 1/r32/ecx 4/disp8 . # copy eax+ecx+4 to ecx 05/add-to-eax 4/imm32 - # var slice/ecx : (ref slice) = {eax, ecx} + # var slice/ecx : slice = {eax, ecx} 51/push-ecx 50/push-eax 89/copy 3/mod/direct 1/rm32/ecx . . . 4/r32/esp . . # copy esp to ecx @@ -476,7 +476,7 @@ test-parse-hex-int-multi-digit: 8b/copy 0/mod/indirect 0/rm32/eax . . . 1/r32/ecx . . # copy *eax to ecx 8d/copy-address 1/mod/*+disp8 4/rm32/sib 0/base/eax 1/index/ecx . 1/r32/ecx 4/disp8 . # copy eax+ecx+4 to ecx 05/add-to-eax 4/imm32 - # var slice/ecx : (ref slice) = {eax, ecx} + # var slice/ecx : slice = {eax, ecx} 51/push-ecx 50/push-eax 89/copy 3/mod/direct 1/rm32/ecx . . . 4/r32/esp . . # copy esp to ecx @@ -510,7 +510,7 @@ test-parse-hex-int-0x-prefix: 8b/copy 0/mod/indirect 0/rm32/eax . . . 1/r32/ecx . . # copy *eax to ecx 8d/copy-address 1/mod/*+disp8 4/rm32/sib 0/base/eax 1/index/ecx . 1/r32/ecx 4/disp8 . # copy eax+ecx+4 to ecx 05/add-to-eax 4/imm32 - # var slice/ecx : (ref slice) = {eax, ecx} + # var slice/ecx : slice = {eax, ecx} 51/push-ecx 50/push-eax 89/copy 3/mod/direct 1/rm32/ecx . . . 4/r32/esp . . # copy esp to ecx @@ -544,7 +544,7 @@ test-parse-hex-int-zero: 8b/copy 0/mod/indirect 0/rm32/eax . . . 1/r32/ecx . . # copy *eax to ecx 8d/copy-address 1/mod/*+disp8 4/rm32/sib 0/base/eax 1/index/ecx . 1/r32/ecx 4/disp8 . # copy eax+ecx+4 to ecx 05/add-to-eax 4/imm32 - # var slice/ecx : (ref slice) = {eax, ecx} + # var slice/ecx : slice = {eax, ecx} 51/push-ecx 50/push-eax 89/copy 3/mod/direct 1/rm32/ecx . . . 4/r32/esp . . # copy esp to ecx @@ -578,7 +578,7 @@ test-parse-hex-int-0-prefix: 8b/copy 0/mod/indirect 0/rm32/eax . . . 1/r32/ecx . . # copy *eax to ecx 8d/copy-address 1/mod/*+disp8 4/rm32/sib 0/base/eax 1/index/ecx . 1/r32/ecx 4/disp8 . # copy eax+ecx+4 to ecx 05/add-to-eax 4/imm32 - # var slice/ecx : (ref slice) = {eax, ecx} + # var slice/ecx : slice = {eax, ecx} 51/push-ecx 50/push-eax 89/copy 3/mod/direct 1/rm32/ecx . . . 4/r32/esp . . # copy esp to ecx @@ -612,7 +612,7 @@ test-parse-hex-int-negative: 8b/copy 0/mod/indirect 0/rm32/eax . . . 1/r32/ecx . . # copy *eax to ecx 8d/copy-address 1/mod/*+disp8 4/rm32/sib 0/base/eax 1/index/ecx . 1/r32/ecx 4/disp8 . # copy eax+ecx+4 to ecx 05/add-to-eax 4/imm32 - # var slice/ecx : (ref slice) = {eax, ecx} + # var slice/ecx : slice = {eax, ecx} 51/push-ecx 50/push-eax 89/copy 3/mod/direct 1/rm32/ecx . . . 4/r32/esp . . # copy esp to ecx |