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

Function findSemicolon

lib/tokenize.cpp:2690–2702  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2688 }
2689
2690 Token *findSemicolon(Token *tok)
2691 {
2692 int level = 0;
2693
2694 for (; tok && (level > 0 || tok->str() != ";"); tok = tok->next()) {
2695 if (tok->str() == "{")
2696 ++level;
2697 else if (level > 0 && tok->str() == "}")
2698 --level;
2699 }
2700
2701 return tok;
2702 }
2703
2704 bool usingMatch(
2705 const Token *nameToken,

Callers 2

usingMatchFunction · 0.85
simplifyUsingMethod · 0.85

Calls 2

nextMethod · 0.80
strMethod · 0.45

Tested by

no test coverage detected