From 178b28099fa542430a8e9491e23053a162aedcb9 Mon Sep 17 00:00:00 2001 From: Richo Healey Date: Tue, 15 Mar 2016 19:50:11 +0100 Subject: [PATCH] syntax: impl ToTokens for P --- src/libsyntax/ext/quote.rs | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/libsyntax/ext/quote.rs b/src/libsyntax/ext/quote.rs index 38da478b5edaf..77aeaf8459aec 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,