Skip to content

clang/lib/Frontend/InterfaceStubFunctionsConsumer.cpp:298: Poor choice of range variable type ? #90285

Closed
@dcb314

Description

@dcb314

Static analyser cppcheck says:

clang/lib/Frontend/InterfaceStubFunctionsConsumer.cpp:298:19: performance: Range variable 'Name' should be declared as const reference. [iterateByValue]

Source code is

   for (auto Name : Symbol.Names) {

Suggest code rework.

Metadata

Metadata

Assignees

Labels

clang:frontendLanguage frontend issues, e.g. anything involving "Sema"code-qualitygood first issuehttps://github.com/llvm/llvm-project/contribute

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions