Skip to content

Commit

Permalink
Update checkother.cpp
Browse files Browse the repository at this point in the history
  • Loading branch information
chrchr-github authored Nov 14, 2024
1 parent 648d1c8 commit 2f9bc54
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion lib/checkother.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1407,8 +1407,11 @@ void CheckOther::checkPassByReference()
if (inconclusive && !mSettings->certainty.isEnabled(Certainty::inconclusive))
continue;

if (var->isArray() && var->getTypeName() != "std::array")
continue;

const bool isConst = var->isConst();
if (isConst && !var->isArray()) {
if (isConst) {
passedByValueError(var, inconclusive, isRangeBasedFor);
continue;
}
Expand Down

0 comments on commit 2f9bc54

Please sign in to comment.