diff options
| author | Roy Frostig <[email protected]> | 2010-06-24 08:13:32 -0700 |
|---|---|---|
| committer | Roy Frostig <[email protected]> | 2010-06-24 08:13:32 -0700 |
| commit | bc286c7f2ceb5c3d2e06ec72f78d28842f94ef65 (patch) | |
| tree | eac0b9f72ce3a7c97440bc76f38f5159ecc2cdfb /src/boot/me/trans.ml | |
| parent | Update README to point to github, test email notification. (diff) | |
| download | rust-bc286c7f2ceb5c3d2e06ec72f78d28842f94ef65.tar.xz rust-bc286c7f2ceb5c3d2e06ec72f78d28842f94ef65.zip | |
Resolve and typecheck patterns in pattern alt.
Diffstat (limited to 'src/boot/me/trans.ml')
| -rw-r--r-- | src/boot/me/trans.ml | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/boot/me/trans.ml b/src/boot/me/trans.ml index bca15136..a7ff502c 100644 --- a/src/boot/me/trans.ml +++ b/src/boot/me/trans.ml @@ -3757,7 +3757,8 @@ let trans_visitor emit (Il.jmp Il.JNE Il.CodeNone); [ next_jump ] - | Ast.PAT_tag (ident, pats) -> + | Ast.PAT_tag (tag_namei, pats) -> + let tag_name = tag_namei.node in let ty_tag = match ty with Ast.TY_tag tag_ty -> tag_ty @@ -3765,7 +3766,6 @@ let trans_visitor | _ -> bug cx "expected tag type" in let tag_keys = sorted_htab_keys ty_tag in - let tag_name = Ast.NAME_base (Ast.BASE_ident ident) in let tag_number = arr_idx tag_keys tag_name in let ty_tup = Hashtbl.find ty_tag tag_name in |