MCPcopy Create free account
hub / github.com/cppcheck-opensource/cppcheck / deleteToken

Function deleteToken

externals/simplecpp/simplecpp.h:343–357  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

341 }
342
343 void deleteToken(Token *tok) {
344 if (!tok)
345 return;
346 Token * const prev = tok->previous;
347 Token * const next = tok->next;
348 if (prev)
349 prev->next = next;
350 if (next)
351 next->previous = prev;
352 if (frontToken == tok)
353 frontToken = next;
354 if (backToken == tok)
355 backToken = prev;
356 delete tok;
357 }
358
359 void takeTokens(TokenList &other) {
360 if (!other.frontToken)

Callers 15

removeTemplateMethod · 0.85
lineDirectiveMethod · 0.85
readfileMethod · 0.85
constFoldMethod · 0.85
combineOperatorsMethod · 0.85
constFoldMulDivRemMethod · 0.85
constFoldAddSubMethod · 0.85
constFoldShiftMethod · 0.85
constFoldComparisonMethod · 0.85
constFoldBitwiseMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected