Skip to content

Commit 88dd984

Browse files
committed
Tokenizer::tokenize(): removed useless const_cast.
No functional change.
1 parent 77d677d commit 88dd984

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

src/tokenize.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -421,7 +421,7 @@ bool Tokenizer::tokenize(std::istream &code, const char FileName[])
421421
{
422422
const char *type1 = tok->strAt(1);
423423
const char *type2 = tok->strAt(2);
424-
tok = const_cast<Token*>(tok->tokAt(3));
424+
tok = tok->tokAt(3);
425425
for (Token *tok2 = tok; tok2; tok2 = tok2->next())
426426
{
427427
if (tok2->str() == type2)
@@ -434,7 +434,7 @@ bool Tokenizer::tokenize(std::istream &code, const char FileName[])
434434
const char *type1 = tok->strAt(1);
435435
const char *type2 = tok->strAt(2);
436436
const char *type3 = tok->strAt(3);
437-
tok = const_cast<Token*>(tok->tokAt(4));
437+
tok = tok->tokAt(4);
438438
for (Token *tok2 = tok; tok2; tok2 = tok2->next())
439439
{
440440
if (tok2->str() == type3)

0 commit comments

Comments
 (0)