aboutsummaryrefslogtreecommitdiff
path: root/clang/lib/StaticAnalyzer/Checkers/StdLibraryFunctionsChecker.cpp
diff options
context:
space:
mode:
authorBalázs Kéri <1.int32@gmail.com>2022-10-26 15:53:53 +0200
committerBalázs Kéri <1.int32@gmail.com>2022-10-26 16:25:10 +0200
commita688b5f92a17dccbad411b41e254addfbd4d2852 (patch)
treea2f963f5547aedfcbd15115313590c2d6daac6e7 /clang/lib/StaticAnalyzer/Checkers/StdLibraryFunctionsChecker.cpp
parente0448245671342ad4f0431aeabef8d575cfd80f5 (diff)
downloadllvm-a688b5f92a17dccbad411b41e254addfbd4d2852.zip
llvm-a688b5f92a17dccbad411b41e254addfbd4d2852.tar.gz
llvm-a688b5f92a17dccbad411b41e254addfbd4d2852.tar.bz2
[clang][ASTImporter] Remove use of ParentMapContext.
Function 'isAncestorDeclContextOf' was using 'ParentMapContext' for looking up parent of statement nodes. There may be cases (bugs?) with ParentMapContext when parents of specific statements are not found. This leads to 'ASTImporter' infinite import loops when function 'hasAutoReturnTypeDeclaredInside' returns false incorrectly. A real case was found but could not be reproduced with test code. Use of 'ParentMapContext' is now removed and changed to a more safe (currently) method by searching for declarations in statements and find parent of these declarations. The new code was tested on a number of projects and no related crash was found. Reviewed By: martong Differential Revision: https://reviews.llvm.org/D136684
Diffstat (limited to 'clang/lib/StaticAnalyzer/Checkers/StdLibraryFunctionsChecker.cpp')
0 files changed, 0 insertions, 0 deletions