diff options
author | Kartik K. Agaram <vc@akkartik.com> | 2014-11-04 13:43:57 -0800 |
---|---|---|
committer | Kartik K. Agaram <vc@akkartik.com> | 2014-11-04 13:43:57 -0800 |
commit | 101ee552633752932bcd129add2f021f05ee680e (patch) | |
tree | 5bdd832e6a09e08982f5310200f6b39439d94d31 /mu.arc | |
parent | f27613a982b8a0d216802adfe22178c6670e40f5 (diff) | |
download | mu-101ee552633752932bcd129add2f021f05ee680e.tar.gz |
223
Diffstat (limited to 'mu.arc')
-rw-r--r-- | mu.arc | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/mu.arc b/mu.arc index be5b014c..69afae51 100644 --- a/mu.arc +++ b/mu.arc @@ -680,6 +680,7 @@ (if (in op 'get 'get-address) (with (basetype (typeinfo args.0) field (v args.1)) + ; todo: need to rename args.0 as well? (when (pos 'deref (metadata args.0)) (assert basetype!address "@args.0 requests deref, but it's not an address of a record") (= basetype (types* basetype!elem))) @@ -694,11 +695,11 @@ (assert (~isa-field v.arg) "arg @arg is also a field name") (when (maybe-add arg offset idx) (err "use before set: @arg") - (++ idx)))) + (++ idx (sizeof ty.arg))))) (each arg oargs (assert (~isa-field v.arg) "oarg @arg is also a field name") (when (maybe-add arg offset idx) - (++ idx)))))) + (++ idx (sizeof ty.arg))))))) (each instr instrs (let (oargs op args) (parse-instr instr) (each arg args |