diff options
Diffstat (limited to 'apps/mu.subx')
-rw-r--r-- | apps/mu.subx | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/apps/mu.subx b/apps/mu.subx index 1b68350f..b3cb99de 100644 --- a/apps/mu.subx +++ b/apps/mu.subx @@ -14518,6 +14518,13 @@ size-of-type-id: # t: type-id -> result/eax: int b8/copy-to-eax 8/imm32 eb/jump $size-of-type-id:end/disp8 # eax changes type from type-id to int } + # if t is a slice, return 8 + 3d/compare-eax-and 0xc/imm32/slice + { + 75/jump-if-!= break/disp8 + b8/copy-to-eax 8/imm32 + eb/jump $size-of-type-id:end/disp8 # eax changes type from type-id to int + } # if t is a user-defined type, return its size # TODO: support non-atom type (find-typeinfo %eax %ecx) |