diff options
| author | Graydon Hoare <[email protected]> | 2010-09-20 20:19:22 -0700 |
|---|---|---|
| committer | Graydon Hoare <[email protected]> | 2010-09-20 20:19:22 -0700 |
| commit | c17964c06d24300e5f9073f0b7ab4ffaffd78a89 (patch) | |
| tree | 7996174fc01f36e5434dd57c68b323c7806025bf /src/boot/me/semant.ml | |
| parent | Add issue #163 testcase to str-append testcase. (diff) | |
| download | rust-c17964c06d24300e5f9073f0b7ab4ffaffd78a89.tar.xz rust-c17964c06d24300e5f9073f0b7ab4ffaffd78a89.zip | |
Use name_base in plval base.
Diffstat (limited to 'src/boot/me/semant.ml')
| -rw-r--r-- | src/boot/me/semant.ml | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/src/boot/me/semant.ml b/src/boot/me/semant.ml index 01457454..0d350bc5 100644 --- a/src/boot/me/semant.ml +++ b/src/boot/me/semant.ml @@ -579,10 +579,8 @@ let rec lval_to_name (lv:Ast.lval) : Ast.name = let rec plval_to_name (pl:Ast.plval) : Ast.name = match pl with - Ast.PLVAL_ident ident -> - Ast.NAME_base (Ast.BASE_ident ident) - | Ast.PLVAL_app (ident, tys) -> - Ast.NAME_base (Ast.BASE_app (ident, tys)) + Ast.PLVAL_base nb -> + Ast.NAME_base nb | Ast.PLVAL_ext_name ({node = Ast.PEXP_lval pl}, nc) -> Ast.NAME_ext (plval_to_name pl, nc) | _ -> bug () "plval_to_name with plval that contains non-name components" @@ -1431,8 +1429,7 @@ let rec pexp_is_const (cx:ctxt) (pexp:Ast.pexp) : bool = and plval_is_const (cx:ctxt) (plval:Ast.plval) : bool = match plval with - Ast.PLVAL_ident _ - | Ast.PLVAL_app _ -> + Ast.PLVAL_base _ -> bug () "Semant.plval_is_const on plval base" | Ast.PLVAL_ext_name (pexp, _) -> |