Fix code generation of unexposed entities
This commit is contained in:
parent
69ca035b5a
commit
36d2a815a3
1 changed files with 6 additions and 4 deletions
|
|
@ -1034,7 +1034,10 @@ namespace
|
||||||
code_generator::output output(type_safe::ref(generator), type_safe::ref(entity),
|
code_generator::output output(type_safe::ref(generator), type_safe::ref(entity),
|
||||||
cur_access);
|
cur_access);
|
||||||
if (output)
|
if (output)
|
||||||
|
{
|
||||||
detail::write_token_string(output, entity.spelling());
|
detail::write_token_string(output, entity.spelling());
|
||||||
|
output << newl;
|
||||||
|
}
|
||||||
return static_cast<bool>(output);
|
return static_cast<bool>(output);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -1196,10 +1199,9 @@ void detail::write_token_string(code_generator::output& output, const cpp_token_
|
||||||
// operators that are always binary operators in all contexts
|
// operators that are always binary operators in all contexts
|
||||||
else if (token.spelling.back() == '=' // all assignment operators
|
else if (token.spelling.back() == '=' // all assignment operators
|
||||||
|| token.spelling == "/" || token.spelling == "%" || token.spelling == "=="
|
|| token.spelling == "/" || token.spelling == "%" || token.spelling == "=="
|
||||||
|| token.spelling == "!=" || token.spelling == "<" || token.spelling == ">"
|
|| token.spelling == "!=" || token.spelling == "<=" || token.spelling == ">="
|
||||||
|| token.spelling == "<=" || token.spelling == ">=" || token.spelling == "&&"
|
|| token.spelling == "&&" || token.spelling == "||" || token.spelling == "|"
|
||||||
|| token.spelling == "||" || token.spelling == "|" || token.spelling == "^"
|
|| token.spelling == "^" || token.spelling == "?")
|
||||||
|| token.spelling == "?")
|
|
||||||
output << operator_ws << punctuation(token.spelling) << operator_ws;
|
output << operator_ws << punctuation(token.spelling) << operator_ws;
|
||||||
else
|
else
|
||||||
output << punctuation(token.spelling);
|
output << punctuation(token.spelling);
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue