diff options
| author | Graydon Hoare <[email protected]> | 2010-07-27 11:19:43 -0700 |
|---|---|---|
| committer | Graydon Hoare <[email protected]> | 2010-07-27 11:19:43 -0700 |
| commit | 4d31cf1dc58794b8f72240eb19c48b392e9de7b2 (patch) | |
| tree | a5b4c7eb4cc39dac8d1a86cc13b8526c4c7f730b /src/boot/me/layout.ml | |
| parent | Slight shaving on RA, no more optimizing today. It's fast enough for now. (diff) | |
| download | rust-4d31cf1dc58794b8f72240eb19c48b392e9de7b2.tar.xz rust-4d31cf1dc58794b8f72240eb19c48b392e9de7b2.zip | |
Distill semantics of use-def maps to fewer and more-obvious words.
- Remove redundant uses of 'resolve' and 'referent' in semant.
- Use defn, defn_id, lval, lval_base more consistently.
- Make associated query functions more consistent.
- Closes #127.
Diffstat (limited to 'src/boot/me/layout.ml')
| -rw-r--r-- | src/boot/me/layout.ml | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/boot/me/layout.ml b/src/boot/me/layout.ml index 49aa1340..a9358795 100644 --- a/src/boot/me/layout.ml +++ b/src/boot/me/layout.ml @@ -412,9 +412,9 @@ let layout_visitor let static = lval_is_static cx callee in let closure = if static then None else Some Il.OpaqueTy in let n_ty_params = - match resolve_lval cx callee with - DEFN_item i -> Array.length i.Ast.decl_params - | _ -> 0 + if lval_base_is_item cx callee + then Array.length (lval_item cx callee).node.Ast.decl_params + else 0 in let rty = call_args_referent_type cx n_ty_params lv_ty closure |