Skip to content

Commit 0ae9877

Browse files
authored
Typos found by running "codespell" (#4260)
1 parent c218859 commit 0ae9877

5 files changed

Lines changed: 10 additions & 10 deletions

File tree

cmake/compileroptions.cmake

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -147,7 +147,7 @@ if (MSVC)
147147

148148
# C/C++ - Language
149149
add_compile_options(/Zc:rvalueCast) # Enforce type conversion rules
150-
add_compile_options(/std:c++14) # C++ Langage Standard - ISO C++14 Standard
150+
add_compile_options(/std:c++14) # C++ Language Standard - ISO C++14 Standard
151151

152152
# C/C++ - Browse Information
153153
# Enable Browse Information - No
@@ -184,7 +184,7 @@ if (MSVC)
184184
# Linker - System
185185
# Stack Reserve Size - 8000000
186186
# Stack Commit Size - 8000000
187-
add_link_options(/LARGEADDRESSAWARE) # Enbale Large Addresses - Yes
187+
add_link_options(/LARGEADDRESSAWARE) # Enable Large Addresses - Yes
188188

189189
# Linker - Optimization
190190
add_link_options(/OPT:REF) # References - Yes

lib/programmemory.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -588,7 +588,7 @@ static ValueFlow::Value evaluate(const std::string& op, const ValueFlow::Value&
588588
// Only add, subtract, and compare for non-integers
589589
if (!compareOp && !contains({"+", "-"}, op) && !lhs.isIntValue() && !rhs.isIntValue())
590590
return ValueFlow::Value::unknown();
591-
// Both cant be iterators for non-compare
591+
// Both can't be iterators for non-compare
592592
if (!compareOp && lhs.isIteratorValue() && rhs.isIteratorValue())
593593
return ValueFlow::Value::unknown();
594594
// Symbolic values must be in the same ring
@@ -1332,7 +1332,7 @@ static ValueFlow::Value executeImpl(const Token* expr, ProgramMemory& pm, const
13321332
}
13331333
}
13341334
}
1335-
// Check if functon modifies argument
1335+
// Check if function modifies argument
13361336
visitAstNodes(expr->astOperand2(), [&](const Token* child) {
13371337
if (child->exprId() > 0 && pm.hasValue(child->exprId())) {
13381338
ValueFlow::Value& v = pm.at(child->exprId());

lib/symboldatabase.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1362,7 +1362,7 @@ class CPPCHECKLIB SymbolDatabase {
13621362
SymbolDatabase(const Tokenizer *tokenizer, const Settings *settings, ErrorLogger *errorLogger);
13631363
~SymbolDatabase();
13641364

1365-
/** @brief Information about all namespaces/classes/structrues */
1365+
/** @brief Information about all namespaces/classes/structures */
13661366
std::list<Scope> scopeList;
13671367

13681368
/** @brief Fast access to function scopes */

lib/valueflow.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2436,10 +2436,10 @@ struct ValueFlowAnalyzer : Analyzer {
24362436
Action read = Action::Read;
24372437
const ValueFlow::Value* value = getValue(tok);
24382438
if (value) {
2439-
// Moving a moved value wont change the moved value
2439+
// Moving a moved value won't change the moved value
24402440
if (value->isMovedValue() && isMoveOrForward(tok) != ValueFlow::Value::MoveKind::NonMovedVariable)
24412441
return read;
2442-
// Inserting elements to container wont change the lifetime
2442+
// Inserting elements to container won't change the lifetime
24432443
if (astIsContainer(tok) && value->isLifetimeValue() &&
24442444
contains({Library::Container::Action::PUSH,
24452445
Library::Container::Action::INSERT,
@@ -6526,7 +6526,7 @@ static void valueFlowForLoopSimplify(Token* const bodyStart,
65266526
ErrorLogger* errorLogger,
65276527
const Settings* settings)
65286528
{
6529-
// TODO: Refactor this to use arbitary expressions
6529+
// TODO: Refactor this to use arbitrary expressions
65306530
assert(expr->varId() > 0);
65316531
const Token * const bodyEnd = bodyStart->link();
65326532

tools/test_reduce.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ def runtool(self, filedata=None):
7474

7575
reduce = ReduceTestFail()
7676

77-
# need to have at least 11 lines ending with comma to enter chunked mode and twice as much for second interation
77+
# need to have at least 11 lines ending with comma to enter chunked mode and twice as much for second iteration
7878
filedata = [
7979
'int i,\n',
8080
'j,\n',
@@ -106,7 +106,7 @@ def runtool(self, filedata=None):
106106

107107

108108
def test_combinelines_chunk_2():
109-
"""'filedata' is not changed by the funtion since the data is assigned to a local variable"""
109+
"""'filedata' is not changed by the function since the data is assigned to a local variable"""
110110

111111
reduce = ReduceTest()
112112

0 commit comments

Comments
 (0)