From ee85db852a5a819e559ab00e7a382a34e925447a Mon Sep 17 00:00:00 2001 From: SimplyTheOther Date: Fri, 8 Jan 2021 22:05:03 +0800 Subject: Added type hint to literal creation for cfg! macro --- gcc/rust/expand/rust-macro-expand.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'gcc') diff --git a/gcc/rust/expand/rust-macro-expand.cc b/gcc/rust/expand/rust-macro-expand.cc index de24504..591d96c 100644 --- a/gcc/rust/expand/rust-macro-expand.cc +++ b/gcc/rust/expand/rust-macro-expand.cc @@ -3609,9 +3609,9 @@ MacroExpander::expand_cfg_macro (AST::MacroInvocData &invoc) bool result = invoc.get_meta_items ()[0]->check_cfg_predicate (session); if (result) - return AST::Literal ("true", AST::Literal::BOOL); + return AST::Literal ("true", AST::Literal::BOOL, CORETYPE_BOOL); else - return AST::Literal ("false", AST::Literal::BOOL); + return AST::Literal ("false", AST::Literal::BOOL, CORETYPE_BOOL); } AST::ASTFragment -- cgit v1.1