about summary refs log tree commit diff
path: root/src/libsyntax_ext
diff options
context:
space:
mode:
authorVadim Petrochenkov <vadim.petrochenkov@gmail.com>2015-12-03 05:37:48 +0300
committerVadim Petrochenkov <vadim.petrochenkov@gmail.com>2015-12-16 17:13:16 +0300
commite0ceef5a9e9224baf1f108ede1d1033e5e7fef08 (patch)
tree9b5a2df911400b1ff05bd8d12490dc6c6fccbb2b /src/libsyntax_ext
parentb8157cc67fa25f2944b24f4306151d53d1b80b56 (diff)
downloadrust-e0ceef5a9e9224baf1f108ede1d1033e5e7fef08.tar.gz
rust-e0ceef5a9e9224baf1f108ede1d1033e5e7fef08.zip
Add ExprType to HIR and make everything compile
+ Apply parser changes manually
+ Add feature gate
Diffstat (limited to 'src/libsyntax_ext')
-rw-r--r--src/libsyntax_ext/asm.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/libsyntax_ext/asm.rs b/src/libsyntax_ext/asm.rs
index 20b89b0e9db..12eabe0edfd 100644
--- a/src/libsyntax_ext/asm.rs
+++ b/src/libsyntax_ext/asm.rs
@@ -62,8 +62,8 @@ pub fn expand_asm<'cx>(cx: &'cx mut ExtCtxt, sp: Span, tts: &[ast::TokenTree])
     // parsed as `asm!(z)` with `z = "x": y` which is type ascription.
     let first_colon = tts.iter().position(|tt| {
         match *tt {
-            ast::TtToken(_, token::Colon) |
-            ast::TtToken(_, token::ModSep) => true,
+            ast::TokenTree::Token(_, token::Colon) |
+            ast::TokenTree::Token(_, token::ModSep) => true,
             _ => false
         }
     }).unwrap_or(tts.len());
@@ -99,7 +99,7 @@ pub fn expand_asm<'cx>(cx: &'cx mut ExtCtxt, sp: Span, tts: &[ast::TokenTree])
 
                 // This is most likely malformed.
                 if p2.token != token::Eof {
-                    let mut extra_tts = p2.parse_all_token_trees();
+                    let mut extra_tts = panictry!(p2.parse_all_token_trees());
                     extra_tts.extend(tts[first_colon..].iter().cloned());
                     p = parse::tts_to_parser(cx.parse_sess, extra_tts, cx.cfg());
                 }