Remove special casing of leading '-' in UDQ parsing
This commit is contained in:
parent
e9dadcf93e
commit
716b4d3bf1
@ -189,16 +189,7 @@ UDQDefine::UDQDefine(const UDQParams& udq_params,
|
||||
}
|
||||
}
|
||||
}
|
||||
/*
|
||||
This is hysterical special casing; the parser does not correctly handle a
|
||||
leading '-' to change sign; we just hack it up by adding a fictious '0'
|
||||
token in front.
|
||||
*/
|
||||
if (string_tokens[0] == "-")
|
||||
string_tokens.insert( string_tokens.begin(), "0" );
|
||||
std::vector<UDQToken> tokens = make_tokens(string_tokens);
|
||||
|
||||
|
||||
this->ast = std::make_shared<UDQASTNode>( UDQParser::parse(udq_params, this->m_var_type, this->m_keyword, this->m_location, tokens, parseContext, errors) );
|
||||
this->string_data = "";
|
||||
for (std::size_t index = 0; index < deck_data.size(); index++) {
|
||||
|
Loading…
Reference in New Issue
Block a user