From 1b730b5e4e1aff438d07f60e0790894ee125fca3 Mon Sep 17 00:00:00 2001 From: John Hodge Date: Mon, 7 Nov 2016 09:15:53 +0800 Subject: Expand - Handle another rustc internal macro --- src/expand/rustc_diagnostics.cpp | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'src') diff --git a/src/expand/rustc_diagnostics.cpp b/src/expand/rustc_diagnostics.cpp index b5337d26..2deaa9a3 100644 --- a/src/expand/rustc_diagnostics.cpp +++ b/src/expand/rustc_diagnostics.cpp @@ -25,7 +25,16 @@ class CExpanderDiagnosticUsed: return box$( TTStreamO(TokenTree()) ); } }; +class CExpanderBuildDiagnosticArray: + public ExpandProcMacro +{ + ::std::unique_ptr expand(const Span& sp, const AST::Crate& crate, const ::std::string& ident, const TokenTree& tt, AST::Module& mod) override + { + return box$( TTStreamO(TokenTree()) ); + } +}; STATIC_MACRO("__register_diagnostic", CExpanderRegisterDiagnostic) STATIC_MACRO("__diagnostic_used", CExpanderDiagnosticUsed) +STATIC_MACRO("__build_diagnostic_array", CExpanderBuildDiagnosticArray) -- cgit v1.2.3