about summary refs log tree commit diff
path: root/src/libsyntax
diff options
context:
space:
mode:
authorJakub Wieczorek <jakub@jakub.cc>2014-08-17 22:10:25 +0200
committerJakub Wieczorek <jakub@jakub.cc>2014-08-18 00:08:57 +0200
commitd283574558b98b659997fd7bc97028158297388c (patch)
tree26daf5ada3b0df480cc970008b609568e204ed53 /src/libsyntax
parenta12a4ddcfabb80d6224960f19d6043f88f47d1e6 (diff)
downloadrust-d283574558b98b659997fd7bc97028158297388c.tar.gz
rust-d283574558b98b659997fd7bc97028158297388c.zip
Forbid extern statics from appearing in patterns
Fixes #16149.
Diffstat (limited to 'src/libsyntax')
-rw-r--r--src/libsyntax/ast_util.rs15
1 files changed, 0 insertions, 15 deletions
diff --git a/src/libsyntax/ast_util.rs b/src/libsyntax/ast_util.rs
index 5674c6675f9..1a4b41404be 100644
--- a/src/libsyntax/ast_util.rs
+++ b/src/libsyntax/ast_util.rs
@@ -209,21 +209,6 @@ pub fn name_to_dummy_lifetime(name: Name) -> Lifetime {
                name: name }
 }
 
-pub fn is_unguarded(a: &Arm) -> bool {
-    match a.guard {
-      None => true,
-      _    => false
-    }
-}
-
-pub fn unguarded_pat(a: &Arm) -> Option<Vec<Gc<Pat>>> {
-    if is_unguarded(a) {
-        Some(/* FIXME (#2543) */ a.pats.clone())
-    } else {
-        None
-    }
-}
-
 /// Generate a "pretty" name for an `impl` from its type and trait.
 /// This is designed so that symbols of `impl`'d methods give some
 /// hint of where they came from, (previously they would all just be