X-Git-Url: https://git.lizzy.rs/?a=blobdiff_plain;f=compiler%2Frustc_expand%2Fsrc%2Fproc_macro_server.rs;h=a929f6cb0a5df6d6db89b433c8f133412711e260;hb=163a7090b8c774785c8daea0e95e70e60ccfc6d0;hp=cc2858d3f73a17d80a95147a4353501ca82cc5b4;hpb=7174231ae66aa3e938cbe0b84e23e79d867fec20;p=rust.git diff --git a/compiler/rustc_expand/src/proc_macro_server.rs b/compiler/rustc_expand/src/proc_macro_server.rs index cc2858d3f73..a929f6cb0a5 100644 --- a/compiler/rustc_expand/src/proc_macro_server.rs +++ b/compiler/rustc_expand/src/proc_macro_server.rs @@ -525,6 +525,13 @@ fn expand_expr(&mut self, stream: &Self::TokenStream) -> Result { Ok(tokenstream::TokenStream::token_alone(token::Literal(l.token_lit), l.span)) } + ast::ExprKind::IncludedBytes(bytes) => { + let lit = ast::Lit::from_included_bytes(bytes, expr.span); + Ok(tokenstream::TokenStream::token_alone( + token::TokenKind::Literal(lit.token_lit), + expr.span, + )) + } ast::ExprKind::Unary(ast::UnOp::Neg, e) => match &e.kind { ast::ExprKind::Lit(l) => match l.token_lit { token::Lit { kind: token::Integer | token::Float, .. } => {