aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGraydon Hoare <[email protected]>2011-02-10 19:04:37 -0800
committerGraydon Hoare <[email protected]>2011-02-10 19:04:37 -0800
commitc89460bb659e1af1a3618cfe8d7fa304e531916d (patch)
tree5c369b07500c0e847772939cedfaf2f74e86f77d
parentAdd pat_lit to ast, and support parsing it. (diff)
downloadrust-c89460bb659e1af1a3618cfe8d7fa304e531916d.tar.xz
rust-c89460bb659e1af1a3618cfe8d7fa304e531916d.zip
Support indexing pat_lit.
-rw-r--r--src/comp/front/parser.rs1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/comp/front/parser.rs b/src/comp/front/parser.rs
index 2fa4afeb..87bbe57f 100644
--- a/src/comp/front/parser.rs
+++ b/src/comp/front/parser.rs
@@ -1331,6 +1331,7 @@ fn index_arm(@ast.pat pat) -> hashmap[ast.ident,ast.def_id] {
alt (pat.node) {
case (ast.pat_bind(?i, ?def_id, _)) { index.insert(i, def_id); }
case (ast.pat_wild(_)) { /* empty */ }
+ case (ast.pat_lit(_, _)) { /* empty */ }
case (ast.pat_tag(_, ?pats, _, _)) {
for (@ast.pat p in pats) {
do_index_arm(index, p);