Skip to content

Commit cbe9fb4

Browse files
committed
auto merge of #19463 : kali/rust/master, r=alexcrichton
parse_ty() no longer takes a boolean parameter. quote_ty! implementation has not yet been modified accordingly. As a matter of fact, quote_ty! was not covered by tests. One test (called qquotes) references it, but it has been ignored for nearly one year and now need heavy refactoring. quote_token.rs seemed like a good place to test quote_ty!, many other quote_*! macros were asserted there.
2 parents 95c2ed3 + 8920181 commit cbe9fb4

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

src/libsyntax/ext/quote.rs

+1-2
Original file line numberDiff line numberDiff line change
@@ -450,8 +450,7 @@ pub fn expand_quote_ty(cx: &mut ExtCtxt,
450450
sp: Span,
451451
tts: &[ast::TokenTree])
452452
-> Box<base::MacResult+'static> {
453-
let expanded = expand_parse_call(cx, sp, "parse_ty",
454-
vec![], tts);
453+
let expanded = expand_parse_call(cx, sp, "parse_ty", vec!(), tts);
455454
base::MacExpr::new(expanded)
456455
}
457456

src/test/run-pass-fulldeps/quote-tokens.rs

+2
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,8 @@ fn syntax_extension(cx: &ExtCtxt) {
3838

3939
let _j: P<syntax::ast::Method> = quote_method!(cx, fn foo(&self) {});
4040
let _k: P<syntax::ast::Method> = quote_method!(cx, #[doc = "hello"] fn foo(&self) {});
41+
42+
let _l: P<syntax::ast::Ty> = quote_ty!(cx, &int);
4143
}
4244

4345
fn main() {

0 commit comments

Comments
 (0)