We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 9854ed4 commit 179a7d5Copy full SHA for 179a7d5
cpp/ql/src/Likely Bugs/Format/NonConstantFormat.ql
@@ -49,7 +49,9 @@ predicate cannotContainString(Type t) {
49
not unspecified instanceof WideCharType and
50
not unspecified instanceof Char8Type and
51
not unspecified instanceof Char16Type and
52
- not unspecified instanceof Char32Type
+ not unspecified instanceof Char32Type and
53
+ // C often defines `wchar_t` as `unsigned short`
54
+ unspecified = any(ShortType short | not short.isUnsigned())
55
|
56
unspecified instanceof ArithmeticType or
57
unspecified instanceof BuiltInType
0 commit comments