diff --git a/src/libsyntax/ext/quote.rs b/src/libsyntax/ext/quote.rs index 38da478b5ed..77aeaf8459a 100644 --- a/src/libsyntax/ext/quote.rs +++ b/src/libsyntax/ext/quote.rs @@ -121,6 +121,12 @@ pub mod rt { } } + impl ToTokens for P { + fn to_tokens(&self, _cx: &ExtCtxt) -> Vec { + vec![TokenTree::Token(self.span, token::Interpolated(token::NtImplItem(self.clone())))] + } + } + impl ToTokens for ast::TraitItem { fn to_tokens(&self, _cx: &ExtCtxt) -> Vec { vec![TokenTree::Token(self.span,