@@ -178,7 +178,7 @@ const Token * astIsVariableComparison(const Token *tok, const std::string &comp,
178178bool isVariableDecl (const Token* tok);
179179bool isStlStringType (const Token* tok);
180180
181- bool isTemporary (bool cpp, const Token* tok, const Library* library, bool unknown = false );
181+ bool isTemporary (const Token* tok, const Library* library, bool unknown = false );
182182
183183const Token* previousBeforeAstLeftmostLeaf (const Token* tok);
184184Token* previousBeforeAstLeftmostLeaf (Token* tok);
@@ -192,7 +192,7 @@ const Token* astParentSkipParens(const Token* tok);
192192const Token* getParentMember (const Token * tok);
193193
194194const Token* getParentLifetime (const Token* tok);
195- const Token* getParentLifetime (bool cpp, const Token* tok, const Library* library);
195+ const Token* getParentLifetime (const Token* tok, const Library* library);
196196
197197std::vector<ValueType> getParentValueTypes (const Token* tok,
198198 const Settings* settings = nullptr ,
@@ -245,7 +245,7 @@ SmallVector<ReferenceToken> followAllReferences(const Token* tok,
245245 int depth = 20 );
246246const Token* followReferences (const Token* tok, ErrorPath* errors = nullptr );
247247
248- CPPCHECKLIB bool isSameExpression (bool cpp, bool macro, const Token *tok1, const Token *tok2, const Library& library, bool pure, bool followVar, ErrorPath* errors=nullptr );
248+ CPPCHECKLIB bool isSameExpression (bool macro, const Token *tok1, const Token *tok2, const Library& library, bool pure, bool followVar, ErrorPath* errors=nullptr );
249249
250250bool isEqualKnownValue (const Token * const tok1, const Token * const tok2);
251251
@@ -261,21 +261,20 @@ CPPCHECKLIB bool isUsedAsBool(const Token* const tok, const Settings* settings =
261261/* *
262262 * Are two conditions opposite
263263 * @param isNot do you want to know if cond1 is !cond2 or if cond1 and cond2 are non-overlapping. true: cond1==!cond2 false: cond1==true => cond2==false
264- * @param cpp c++ file
265264 * @param cond1 condition1
266265 * @param cond2 condition2
267266 * @param library files data
268267 * @param pure boolean
269268 */
270- bool isOppositeCond (bool isNot, bool cpp, const Token * const cond1, const Token * const cond2, const Library& library, bool pure, bool followVar, ErrorPath* errors=nullptr );
269+ bool isOppositeCond (bool isNot, const Token * const cond1, const Token * const cond2, const Library& library, bool pure, bool followVar, ErrorPath* errors=nullptr );
271270
272- bool isOppositeExpression (bool cpp, const Token * const tok1, const Token * const tok2, const Library& library, bool pure, bool followVar, ErrorPath* errors=nullptr );
271+ bool isOppositeExpression (const Token * const tok1, const Token * const tok2, const Library& library, bool pure, bool followVar, ErrorPath* errors=nullptr );
273272
274273bool isConstFunctionCall (const Token* ftok, const Library& library);
275274
276- bool isConstExpression (const Token *tok, const Library& library, bool cpp );
275+ bool isConstExpression (const Token *tok, const Library& library);
277276
278- bool isWithoutSideEffects (bool cpp, const Token* tok, bool checkArrayAccess = false , bool checkReference = true );
277+ bool isWithoutSideEffects (const Token* tok, bool checkArrayAccess = false , bool checkReference = true );
279278
280279bool isUniqueExpression (const Token* tok);
281280
@@ -320,38 +319,35 @@ bool isVariableChangedByFunctionCall(const Token *tok, int indirect, nonneg int
320319CPPCHECKLIB bool isVariableChangedByFunctionCall (const Token *tok, int indirect, const Settings *settings, bool *inconclusive);
321320
322321/* * Is variable changed in block of code? */
323- CPPCHECKLIB bool isVariableChanged (const Token *start, const Token *end, const nonneg int exprid, bool globalvar, const Settings *settings, bool cpp, int depth = 20 );
324- bool isVariableChanged (const Token *start, const Token *end, int indirect, const nonneg int exprid, bool globalvar, const Settings *settings, bool cpp, int depth = 20 );
322+ CPPCHECKLIB bool isVariableChanged (const Token *start, const Token *end, const nonneg int exprid, bool globalvar, const Settings *settings, int depth = 20 );
323+ bool isVariableChanged (const Token *start, const Token *end, int indirect, const nonneg int exprid, bool globalvar, const Settings *settings, int depth = 20 );
325324
326- bool isVariableChanged (const Token *tok, int indirect, const Settings *settings, bool cpp, int depth = 20 );
325+ bool isVariableChanged (const Token *tok, int indirect, const Settings *settings, int depth = 20 );
327326
328- bool isVariableChanged (const Variable * var, const Settings *settings, bool cpp, int depth = 20 );
327+ bool isVariableChanged (const Variable * var, const Settings *settings, int depth = 20 );
329328
330329bool isVariablesChanged (const Token* start,
331330 const Token* end,
332331 int indirect,
333332 const std::vector<const Variable*> &vars,
334- const Settings* settings,
335- bool cpp);
333+ const Settings* settings);
336334
337- bool isThisChanged (const Token* tok, int indirect, const Settings* settings, bool cpp );
338- const Token* findThisChanged (const Token* start, const Token* end, int indirect, const Settings* settings, bool cpp );
335+ bool isThisChanged (const Token* tok, int indirect, const Settings* settings);
336+ const Token* findThisChanged (const Token* start, const Token* end, int indirect, const Settings* settings);
339337
340- const Token* findVariableChanged (const Token *start, const Token *end, int indirect, const nonneg int exprid, bool globalvar, const Settings *settings, bool cpp, int depth = 20 );
341- Token* findVariableChanged (Token *start, const Token *end, int indirect, const nonneg int exprid, bool globalvar, const Settings *settings, bool cpp, int depth = 20 );
338+ const Token* findVariableChanged (const Token *start, const Token *end, int indirect, const nonneg int exprid, bool globalvar, const Settings *settings, int depth = 20 );
339+ Token* findVariableChanged (Token *start, const Token *end, int indirect, const nonneg int exprid, bool globalvar, const Settings *settings, int depth = 20 );
342340
343341CPPCHECKLIB const Token* findExpressionChanged (const Token* expr,
344342 const Token* start,
345343 const Token* end,
346344 const Settings* settings,
347- bool cpp,
348345 int depth = 20 );
349346
350347const Token* findExpressionChangedSkipDeadCode (const Token* expr,
351348 const Token* start,
352349 const Token* end,
353350 const Settings* settings,
354- bool cpp,
355351 const std::function<std::vector<MathLib::bigint>(const Token* tok)>& evaluate,
356352 int depth = 20);
357353
@@ -360,7 +356,6 @@ bool isExpressionChangedAt(const Token* expr,
360356 int indirect,
361357 bool globalvar,
362358 const Settings* settings,
363- bool cpp,
364359 int depth = 20 );
365360
366361// / If token is an alias if another variable
@@ -405,14 +400,14 @@ CPPCHECKLIB const Token *findLambdaStartToken(const Token *last);
405400CPPCHECKLIB const Token *findLambdaEndToken (const Token *first);
406401CPPCHECKLIB Token* findLambdaEndToken (Token* first);
407402
408- bool isLikelyStream (bool cpp, const Token *stream);
403+ bool isLikelyStream (const Token *stream);
409404
410405/* *
411406 * do we see a likely write of rhs through overloaded operator
412407 * s >> x;
413408 * a & x;
414409 */
415- bool isLikelyStreamRead (bool cpp, const Token *op);
410+ bool isLikelyStreamRead (const Token *op);
416411
417412bool isCPPCast (const Token* tok);
418413
@@ -422,7 +417,7 @@ bool isLeafDot(const Token* tok);
422417
423418enum class ExprUsage { None, NotUsed, PassedByReference, Used, Inconclusive };
424419
425- ExprUsage getExprUsage (const Token* tok, int indirect, const Settings* settings, bool cpp );
420+ ExprUsage getExprUsage (const Token* tok, int indirect, const Settings* settings);
426421
427422const Variable *getLHSVariable (const Token *tok);
428423
@@ -437,7 +432,7 @@ bool isScopeBracket(const Token* tok);
437432
438433CPPCHECKLIB bool isNullOperand (const Token *expr);
439434
440- bool isGlobalData (const Token *expr, bool cpp );
435+ bool isGlobalData (const Token *expr);
441436
442437bool isUnevaluated (const Token *tok);
443438
0 commit comments