Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
performance-faster-string-find: Optimize calls to std::string::find() and friends when the needle passed is a single character string literal. performance-for-range-copy: Finds C++11 for ranges where the loop variable is copied in each iteration but it would suffice to obtain it by const reference. performance-implicit-conversion-in-loop: This warning appears in a range-based loop with a loop variable of const ref type where the type of the variable does not match the one returned by the iterator. This means that an implicit conversion happens, which can for example result in expensive deep copies. performance-inefficient-algorithm: Warns on inefficient use of STL algorithms on associative containers. performance-inefficient-vector-operation: Finds possible inefficient std::vector operations (e.g. push_back, emplace_back) that may cause unnecessary memory reallocations. performance-move-const-arg: Warn about inefficient use of std::move, and suggest a fix that removes it. performance-unnecessary-copy-initialization: Finds local variable declarations that are initialized using the copy constructor of a non-trivially-copyable type, where it would suffice to obtain a const reference. performance-unnecessary-value-param: Flags value parameter declarations of expensive to copy types that are copied for each invocation, where it would suffice to pass them by const reference. modernize-make-unique: Finds the creation of std::unique_ptr objects explicitly calling a new expression, and replaces it with a call to std::make_unique. modernize-loop-convert: This check converts for(...; ...; ...) loops to use the new range-based loops in C++11. The MinConfidence option was already set to "reasonable". modernize-use-auto: Use the auto type specifier for variable declarations to improve code readability and maintainability. The MinTypeNameLength option is set to 16 characters. modernize-use-emplace: The check flags insertions to an STL-style container done by calling the push_back method with an explicitly-constructed temporary of the container element type. In this case, the corresponding emplace_back method results in less verbose and potentially more efficient code.
- Loading branch information