Skip to content

Commit 71f28fc

Browse files
committed
bump simplecpp
1 parent 29e2a7e commit 71f28fc

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

externals/simplecpp/simplecpp.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1393,7 +1393,7 @@ namespace simplecpp {
13931393
explicit Macro(std::vector<std::string> &f) : nameTokDef(nullptr), valueToken(nullptr), endToken(nullptr), files(f), tokenListDefine(f), variadic(false), valueDefinedInCode_(false) {}
13941394

13951395
Macro(const Token *tok, std::vector<std::string> &f) : nameTokDef(nullptr), files(f), tokenListDefine(f), valueDefinedInCode_(true) {
1396-
if (sameline(tok->previous, tok))
1396+
if (sameline(tok->previousSkipComments(), tok))
13971397
throw std::runtime_error("bad macro syntax");
13981398
if (tok->op != '#')
13991399
throw std::runtime_error("bad macro syntax");
@@ -3238,7 +3238,7 @@ void simplecpp::preprocess(simplecpp::TokenList &output, const simplecpp::TokenL
32383238
continue;
32393239
}
32403240

3241-
if (rawtok->op == '#' && !sameline(rawtok->previous, rawtok)) {
3241+
if (rawtok->op == '#' && !sameline(rawtok->previousSkipComments(), rawtok)) {
32423242
if (!sameline(rawtok, rawtok->next)) {
32433243
rawtok = rawtok->next;
32443244
continue;

0 commit comments

Comments
 (0)