Skip to content

Commit

Permalink
CID 1474935
Browse files Browse the repository at this point in the history
  • Loading branch information
danmar committed Aug 18, 2024
1 parent cf91f51 commit 59f94b6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/checkunusedvar.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1595,7 +1595,7 @@ bool CheckUnusedVar::isRecordTypeWithoutSideEffects(const Type* type)
continue; // ignore default/deleted constructors
const bool emptyBody = (f.functionScope && Token::simpleMatch(f.functionScope->bodyStart, "{ }"));

const Token* nextToken = f.argDef->link();
const Token* nextToken = f.argDef ? f.argDef->link() : nullptr;
if (Token::simpleMatch(nextToken, ") :")) {
// validating initialization list
nextToken = nextToken->next(); // goto ":"
Expand Down

0 comments on commit 59f94b6

Please sign in to comment.