diff options
author | Alex AUVOLAT <alex.auvolat@ens.fr> | 2013-12-27 11:15:38 +0100 |
---|---|---|
committer | Alex AUVOLAT <alex.auvolat@ens.fr> | 2013-12-27 11:15:38 +0100 |
commit | 0ea39f0178ea94cdb015aef257228f201f9f96b9 (patch) | |
tree | f39bd96bc1b13b8c9e9ccb6c14fc57d8468ea82f /src/typing.ml | |
parent | adee0e08e5c6b71090d057b05a0f96b03c2f708f (diff) | |
download | LPC-Projet-0ea39f0178ea94cdb015aef257228f201f9f96b9.tar.gz LPC-Projet-0ea39f0178ea94cdb015aef257228f201f9f96b9.zip |
Optimize : use regs for argument passing. Still has bugs.
Diffstat (limited to 'src/typing.ml')
-rw-r--r-- | src/typing.ml | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/typing.ml b/src/typing.ml index a405855..966057c 100644 --- a/src/typing.ml +++ b/src/typing.ml @@ -715,16 +715,16 @@ let compute_tclass env c = tp_args = [] }::meth in (* if vtable is empty, remove it *) - let mem = + let mem, mem_u = if hier.h_vtable = [] then let rec mv_h h = h.h_pos <- h.h_pos - 4; List.iter mv_h h.h_supers in List.iter mv_h hier.h_supers; - Smap.map (fun (ty, pos) -> (ty, pos-4)) mem + Smap.map (fun (ty, pos) -> (ty, pos-4)) mem, mem_u - 4 else - mem + mem, mem_u in { tc_name = cls_name; tc_size = mem_u; |