Revision tags: llvmorg-3.3.0, llvmorg-3.3.0-rc3, llvmorg-3.3.0-rc2, llvmorg-3.3.0-rc1 |
|
#
61e221f6 |
| 09-Apr-2013 |
Jordan Rose <jordan_rose@apple.com> |
[analyzer] Replace isIntegerType() with isIntegerOrEnumerationType().
Previously, the analyzer used isIntegerType() everywhere, which uses the C definition of "integer". The C++ predicate with the s
[analyzer] Replace isIntegerType() with isIntegerOrEnumerationType().
Previously, the analyzer used isIntegerType() everywhere, which uses the C definition of "integer". The C++ predicate with the same behavior is isIntegerOrUnscopedEnumerationType().
However, the analyzer is /really/ using this to ask if it's some sort of "integrally representable" type, i.e. it should include C++11 scoped enumerations as well. hasIntegerRepresentation() sounds like the right predicate, but that includes vectors, which the analyzer represents by its elements.
This commit audits all uses of isIntegerType() and replaces them with the general isIntegerOrEnumerationType(), except in some specific cases where it makes sense to exclude scoped enumerations, or any enumerations. These cases now use isIntegerOrUnscopedEnumerationType() and getAs<BuiltinType>() plus BuiltinType::isInteger().
isIntegerType() is hereby banned in the analyzer - lib/StaticAnalysis and include/clang/StaticAnalysis. :-)
Fixes real assertion failures. PR15703 / <rdar://problem/12350701>
llvm-svn: 179081
show more ...
|
#
0d8779cb |
| 08-Feb-2013 |
Anna Zaks <ganna@apple.com> |
[analyzer] Move DefaultBool so that all checkers can share it.
llvm-svn: 174782
|
Revision tags: llvmorg-3.2.0, llvmorg-3.2.0-rc3 |
|
#
3a02247d |
| 04-Dec-2012 |
Chandler Carruth <chandlerc@gmail.com> |
Sort all of Clang's files under 'lib', and fix up the broken headers uncovered.
This required manually correcting all of the incorrect main-module headers I could find, and running the new llvm/util
Sort all of Clang's files under 'lib', and fix up the broken headers uncovered.
This required manually correcting all of the incorrect main-module headers I could find, and running the new llvm/utils/sort_includes.py script over the files.
I also manually added quite a few missing headers that were uncovered by shuffling the order or moving headers up to be main-module-headers.
llvm-svn: 169237
show more ...
|
Revision tags: llvmorg-3.2.0-rc2, llvmorg-3.2.0-rc1 |
|
#
26a3661a |
| 12-Oct-2012 |
Ted Kremenek <kremenek@apple.com> |
Silence static analyzer issue by documenting that in this context that a DeclRefExpr can never return a null decl. We possibly should hoist this into getDecl() itself.
llvm-svn: 165841
|
#
9fa28855 |
| 08-Aug-2012 |
Eli Friedman <eli.friedman@gmail.com> |
clang support for Bitrig (an OpenBSD fork); patch by David Hill.
llvm-svn: 161546
|
#
afddb9c8 |
| 29-Jun-2012 |
Ted Kremenek <kremenek@apple.com> |
Revert "Tweak insecureAPI analyzer checks to have the ability to be individually disabled."
Jordan Rose corrected me that this actually isn't needed.
llvm-svn: 159462
|
#
a33b078e |
| 29-Jun-2012 |
Ted Kremenek <kremenek@apple.com> |
Tweak insecureAPI analyzer checks to have the ability to be individually disabled.
The solution is a bit inefficient: it creates N checkers, one for each check, and each check does a dispatch on the
Tweak insecureAPI analyzer checks to have the ability to be individually disabled.
The solution is a bit inefficient: it creates N checkers, one for each check, and each check does a dispatch on the function name. This is redundant, but we can fix this once we have the proper ability to enable/disable subchecks.
Fixes <rdar://problem/11780180>.
llvm-svn: 159459
show more ...
|
Revision tags: llvmorg-3.1.0, llvmorg-3.1.0-rc3, llvmorg-3.1.0-rc2, llvmorg-3.1.0-rc1 |
|
#
5a10f08b |
| 04-Apr-2012 |
Ted Kremenek <kremenek@apple.com> |
Include the "issue context" (e.g. function or method) where a static analyzer issue occurred in the plist output.
Fixes <rdar://problem/11004527>
llvm-svn: 154030
|
#
2c1dd271 |
| 05-Feb-2012 |
Dylan Noblesmith <nobled@dreamwidth.org> |
Basic: import SmallString<> into clang namespace
(I was going to fix the TODO about DenseMap too, but that would break self-host right now. See PR11922.)
llvm-svn: 149799
|
#
4903802f |
| 04-Feb-2012 |
Benjamin Kramer <benny.kra@googlemail.com> |
Move a method from IdentifierTable.h out of line and remove the SmallString include.
Fix all the transitive include users.
llvm-svn: 149783
|
#
ee5e8ae8 |
| 31-Jan-2012 |
Anna Zaks <ganna@apple.com> |
[analyzer] Change the warning to suggest 'strlcat/strlcpy' as replacements for 'starcat/strcpy' instead of 'strncat/strncpy'.
llvm-svn: 149406
|
#
89eaf8d5 |
| 20-Jan-2012 |
Ted Kremenek <kremenek@apple.com> |
Implement checker that looks for calls to mktemps and friends that have fewer than 6 Xs. Implements <rdar://problem/6336672>.
llvm-svn: 148531
|
#
c54dc951 |
| 20-Jan-2012 |
Ted Kremenek <kremenek@apple.com> |
Turn 'SecuritySyntaxChecker' into a "meta" security checker for insecure APIs. Now multiple checks are exposed as separate checkers, but CheckerManager only creates one Checker object.
llvm-svn: 14
Turn 'SecuritySyntaxChecker' into a "meta" security checker for insecure APIs. Now multiple checks are exposed as separate checkers, but CheckerManager only creates one Checker object.
llvm-svn: 148525
show more ...
|
Revision tags: llvmorg-3.0.0, llvmorg-3.0.0-rc4, llvmorg-3.0.0-rc3, llvmorg-3.0.0-rc2 |
|
#
81ce1c8a |
| 24-Oct-2011 |
Ted Kremenek <kremenek@apple.com> |
Rename AnalysisContext to AnalysisDeclContext. Not only is this name more accurate, but it frees up the name AnalysisContext for other uses.
llvm-svn: 142782
|
Revision tags: llvmorg-3.0.0-rc1 |
|
#
b89514a9 |
| 14-Oct-2011 |
Benjamin Kramer <benny.kra@googlemail.com> |
Change operator<< for raw_ostream and NamedDecl to take a reference instead of a pointer.
Passing a pointer was a bad idea as it collides with the overload for void*.
llvm-svn: 141971
|
#
fedf5dfc |
| 11-Oct-2011 |
Anna Zaks <ganna@apple.com> |
[analyzer] Warn about the use of insecure, deprecated vfork() function PR11053 (http://llvm.org/bugs/show_bug.cgi?id=11053).
A patch by Graham Lee!
llvm-svn: 141643
|
#
c29bed39 |
| 20-Sep-2011 |
Anna Zaks <ganna@apple.com> |
[analyzer] Refactor PathDiagnosticLocation: Make PathDiagnosticLocation(SourceLocation...) private. Most of the effort here goes to making BugReport refer to a PathDiagnosticLocation instead of FullS
[analyzer] Refactor PathDiagnosticLocation: Make PathDiagnosticLocation(SourceLocation...) private. Most of the effort here goes to making BugReport refer to a PathDiagnosticLocation instead of FullSourceLocation.
(Another step closer to the goal of having Diagnostics which can recover from invalid SourceLocations.)
llvm-svn: 140182
show more ...
|
#
e8bbc121 |
| 02-Sep-2011 |
Douglas Gregor <dgregor@apple.com> |
Extend the ASTContext constructor to delay the initialization of builtin types (When requested). This is another step toward making ASTUnit build the ASTContext as needed when loading an AST file, ra
Extend the ASTContext constructor to delay the initialization of builtin types (When requested). This is another step toward making ASTUnit build the ASTContext as needed when loading an AST file, rather than doing so after the fact. No actual functionality change (yet).
llvm-svn: 138985
show more ...
|
#
417d5667 |
| 20-Aug-2011 |
Ted Kremenek <kremenek@apple.com> |
Remove dead code.
llvm-svn: 138183
|
#
0e62c1cc |
| 23-Jul-2011 |
Chris Lattner <sabre@nondot.org> |
remove unneeded llvm:: namespace qualifiers on some core types now that LLVM.h imports them into the clang namespace.
llvm-svn: 135852
|
Revision tags: llvmorg-2.9.0 |
|
#
de909e49 |
| 05-Apr-2011 |
Lenny Maiorani <lenny@colorado.edu> |
Add security syntax checker for strcat() which causes the Static Analyzer to generate a warning any time the strcat() function is used with a note suggesting to use a function which provides bounded
Add security syntax checker for strcat() which causes the Static Analyzer to generate a warning any time the strcat() function is used with a note suggesting to use a function which provides bounded buffers. CWE-119.
Also, brings the security syntax checker more inline with coding standards.
llvm-svn: 128916
show more ...
|
#
fca2e961 |
| 03-Apr-2011 |
Lenny Maiorani <lenny@colorado.edu> |
Refactoring the security checker a little bit so that each CallExpr check doesn't get called for each CallExpr. Instead it does a switch and only runs the check for the proper identifier. Slight spee
Refactoring the security checker a little bit so that each CallExpr check doesn't get called for each CallExpr. Instead it does a switch and only runs the check for the proper identifier. Slight speed improvement (probably significant on very large ASTs), and should make it easier and more clear to add more checks for other CallExpr's later.
llvm-svn: 128785
show more ...
|
#
6ffe738f |
| 31-Mar-2011 |
Lenny Maiorani <lenny@colorado.edu> |
Add security syntax checker for strcpy() which causes the Static Analyzer to generate a warning any time the strcpy() function is used with a note suggesting to use a function which provides bounded
Add security syntax checker for strcpy() which causes the Static Analyzer to generate a warning any time the strcpy() function is used with a note suggesting to use a function which provides bounded buffers.
llvm-svn: 128679
show more ...
|
#
70568c2b |
| 31-Mar-2011 |
Lenny Maiorani <lenny@colorado.edu> |
Fix spelling in a comment. (test commit)
llvm-svn: 128670
|
Revision tags: llvmorg-2.9.0-rc3, llvmorg-2.9.0-rc2, llvmorg-2.9.0-rc1 |
|
#
6a5674ff |
| 01-Mar-2011 |
Argyrios Kyrtzidis <akyrtzi@gmail.com> |
[analyzer] Rename CheckerV2 -> Checker.
llvm-svn: 126726
|