chrchr-github
2c7948102a
Fix #10145 FP AssignmentAddressToInteger with enum class ( #3810 )
2022-02-08 16:12:35 +01:00
chrchr-github
e64ea20089
Fix #10527 FP variableScope for if with init-statement ( #3811 )
2022-02-08 16:12:09 +01:00
Daniel Marjamäki
3989408738
Update copyright year
2022-02-05 11:45:17 +01:00
Oliver Stöneberg
171da2e6f9
avoid dependency on transitive includes - based on include-what-you-use ( #3757 )
2022-01-27 19:03:20 +01:00
Oliver Stöneberg
55ff684f34
added unusedFunction self check to CI / cleanups ( #3526 )
2022-01-18 22:02:25 +01:00
Paul Fultz II
7406dd8c94
Fix 10721: Crash in Tokenizer::simplifyTokenList1 ( #3712 )
2022-01-16 12:46:20 +01:00
Paul Fultz II
abb0563cef
Fix 10726: Crash in CheckExceptionSafety::checkRethrowCopy ( #3711 )
2022-01-16 12:35:51 +01:00
Paul Fultz II
0b1cd8626d
Fix 10664: Crash in Token::linkAt ( #3708 )
...
* Fix 10664: Crash in Token::linkAt
* Format
2022-01-14 23:51:01 +01:00
Oliver Stöneberg
6739995e79
removed or annotated some code which is only used in test code ( #3656 )
2022-01-03 12:40:20 +01:00
Chris Lalancette
df1d6cf026
Fix the ability to recognize return types when simplifying attributes. ( #3637 )
...
* Fix the ability to recognize return types when simplifying attributes.
When parsing attributes to remove them, we have to allow for
the case where the return type of the function that follows
the attribute has a namespaced C++ type, like foo::bar .
That means that :: has to be recognized as a valid token.
Fix this in simplifyAttribute, and add tests for this as well.
2021-12-22 19:02:38 +01:00
Daniel Marjamäki
0d7a3a8b26
dump; add 'noreturn' attribute for function calls
2021-12-19 15:32:33 +01:00
chrchr-github
bb327be8e8
Fix #10591 FP unusedStructMember with value-initialized struct and typedef ( #3643 )
2021-12-18 22:55:52 +01:00
Paul Fultz II
16110b6157
Fix 10339: Lambda in leads to analysis fail ( #3629 )
2021-12-15 19:34:18 +01:00
Paul Fultz II
c0af66bb52
Fix 10552: Internal error with unusedFunction ( #3600 )
2021-12-05 15:46:17 +01:00
Paul Fultz II
29dbded4af
Fix 10615: Crash in Token::linkAt ( #3599 )
2021-12-04 12:57:59 +01:00
Paul Fultz II
bc31419da0
Fix 9301: Syntax error when specializing template variable array ( #3601 )
2021-12-04 12:56:25 +01:00
KenPatrickLehrmann
f5f600bafc
Don't simplify template for class names in declarations ( #3505 )
...
* Don't simplify template for class names in declarations
Without the patch, the test would give:
```
Expected:
namespace foo { class Bar ; } class Baz ; class C : Baz { } ;
Actual:
namespace foo { class Bar ; } class Baz ; class foo :: Bar : Baz { } ;
```
* Use valid code in test case
2021-11-06 19:07:45 +01:00
Oliver Stöneberg
cc1a18806c
use -Weverything for clang in CMake / fixed some warnings ( #3519 )
2021-10-24 11:06:48 +02:00
Oliver Stöneberg
99db1f3f22
fixed some compiler warnings ( #3502 )
2021-10-13 12:10:26 +02:00
Paul Fultz II
fc6a791a74
Fix 9766: False positive; suspicious operator is written in declaration ( #3476 )
2021-10-03 09:59:51 +02:00
Paul Fultz II
edd435d5f0
Fix 10491: Crash in unusedFunction on valid C++ code ( #3465 )
2021-09-22 13:03:46 +02:00
Daniel Marjamäki
15eb53b403
Tokenizer: Add 'enum struct' pattern
2021-08-30 20:18:06 +02:00
Daniel Marjamäki
ccfd18b96d
Simplify Typedef: Fixed typedef simplification in expanded tokens
2021-08-29 19:14:53 +02:00
Paul Fultz II
92eb59981d
Fix 10435: False positive: containerOutOfBounds ( #3426 )
2021-08-29 15:40:10 +02:00
Paul Fultz II
c0765c451d
Fix 10139: AST broken; std::enable_if_t<> ( #3424 )
2021-08-28 09:28:56 +02:00
chrchr-github
d9b6940070
Cleanup: unnecessary includes, fix include order, fix unreferenced va… ( #3418 )
2021-08-26 19:36:31 +02:00
Daniel Marjamäki
ca50dea97d
Fix in Tokenizer::simplifyUsing for non-scopes
2021-08-21 10:10:40 +02:00
Daniel Marjamäki
d73ab0ad96
Tokenizer::simplifyUsing; Fixed bug when enum class is used
2021-08-20 16:08:01 +02:00
Paul Fultz II
422e411b6c
Fix 9444: Syntax error on valid C++14 code ( #3403 )
2021-08-15 07:43:02 +02:00
Paul Fultz II
6d65f86871
Fix 9245: Synax error on valid C++14 code: AST broken, binary operator '=' doesn't have two operands. ( #3400 )
2021-08-14 22:50:58 +02:00
Paul Fultz II
818fd248e1
Simplify template keyword bracket ( #3399 )
2021-08-14 21:16:27 +02:00
Paul Fultz II
7f358b2bed
Format with uncrustify ( #3388 )
2021-08-07 20:51:18 +02:00
Paul Fultz II
00eb71fd49
Remove constexpr -> const simplification ( #3346 )
2021-07-22 07:22:26 +02:00
Daniel Marjamäki
d1fe34e167
misra; implement rule 8.10
2021-07-18 21:18:07 +02:00
Daniel Marjamäki
13d55c7060
misra; implement rule 2.3
2021-07-07 15:16:53 +02:00
Daniel Marjamäki
00a9671f46
misra: implement 8.1
2021-07-07 13:34:55 +02:00
Daniel Marjamäki
9172f2ab3b
addons; add CTU infrastructure
2021-07-07 10:58:13 +02:00
Robert Reif
68898e2be0
fix #10335 (Type alias remains unknown with using) ( #3323 )
...
Co-authored-by: Robert Reif <reif@FX6840>
2021-07-02 06:19:26 +02:00
Daniel Marjamäki
2a2e071a85
Tokenizer::simplifyAttribute; Set function attribute for function pointer
2021-06-26 14:23:39 +02:00
Daniel Marjamäki
3c3435dd10
Fix bug in Tokenizer::simplifyVarDecl
2021-06-06 08:13:40 +02:00
dummyunit
9652ca39a3
Improve support for labels in simplifyAddBraces step ( #3278 )
...
Previously only a single regular label before a compound statement was
allowed in simplifyAddBracesPair() after if/switch/do/while/for.
This patch adds support for:
* case-labels;
* labels before a single statement;
* labels before try/catch blocks;
* multiple consecutive labels.
Additionally the code for skipping a case label was extracted into a
separate function from simplifyLabelsCaseDefault() and reused in
simplifyAddBracesPair().
2021-06-02 07:00:37 +02:00
Robert Reif
3af3d7fc06
fix #10281 (Tokenizer; Wrong simplification for 'namespace ef = : 🅰️ 🅱️ :c::d::ef') ( #3263 )
2021-05-20 08:27:07 +02:00
Daniel Marjamäki
7ba9e37296
unhandled char literal; changed severity to 'portability'. hopefully there will not be warnings for standard character literals.
2021-05-13 13:51:53 +02:00
Daniel Marjamäki
fca7a270bf
daca@home; show unhandled chars diagnostics
2021-05-13 13:44:32 +02:00
Daniel Marjamäki
895a96f9dd
Tokenizer::findGarbageCode: detect wrong struct declaration
2021-05-08 15:28:21 +02:00
Daniel Marjamäki
abb4200316
Fixed #10196 ("Unhandled char constant 'x'" with non-standard escape character)
2021-05-08 12:54:18 +02:00
keinflue
0a84ad874c
Fix case ranges with single quotes and escape sequences ( #3248 )
2021-05-08 11:24:07 +02:00
dummyunit
da27159d7c
Fixed #9728 (Support function level try blocks)
2021-05-02 09:05:12 +02:00
Daniel Marjamäki
a32d6257d5
Fix Cppcheck self-check, extra whitespace in match patterns
2021-05-01 12:15:54 +02:00
Daniel Marjamäki
9b717b8835
Refactoring __attribute__ simplification
2021-05-01 11:39:26 +02:00