[PATCH] D53274: [analyzer][NFC] Fix inconsistencies in AnalyzerOptions

2018-10-21 Thread Umann Kristóf via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Szelethus marked 3 inline comments as done. Closed by commit rL344870: [analyzer][NFC] Fix inconsistencies in AnalyzerOptions (authored by Szelethus, committed by ). Herald added a subscriber: llvm-commits. Changed prior to

[PATCH] D53274: [analyzer][NFC] Fix inconsistencies in AnalyzerOptions

2018-10-19 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ accepted this revision. NoQ added a comment. This revision is now accepted and ready to land. Herald added a subscriber: dkrupp. Thanks! Let's commit. https://reviews.llvm.org/D53274 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http:/

[PATCH] D53274: [analyzer][NFC] Fix inconsistencies in AnalyzerOptions

2018-10-15 Thread Umann Kristóf via Phabricator via cfe-commits
Szelethus marked 2 inline comments as done. Szelethus added inline comments. Comment at: lib/StaticAnalyzer/Core/AnalyzerOptions.cpp:354 +StringRef AnalyzerOptions::getOptionAsString(Optional &V, + StringRef Name, geo

[PATCH] D53274: [analyzer][NFC] Fix inconsistencies in AnalyzerOptions

2018-10-15 Thread George Karpenkov via Phabricator via cfe-commits
george.karpenkov added a comment. OK that makes sense to me, just let's be careful not to crash in places where we weren't crashing before. Comment at: lib/StaticAnalyzer/Core/AnalyzerOptions.cpp:354 +StringRef AnalyzerOptions::getOptionAsString(Optional &V, +

[PATCH] D53274: [analyzer][NFC] Fix inconsistencies in AnalyzerOptions

2018-10-15 Thread Umann Kristóf via Phabricator via cfe-commits
Szelethus added a comment. In https://reviews.llvm.org/D53274#1265625, @george.karpenkov wrote: > I'm not sure why you could get away with removing those llvm_unreachable > cases? Because I got a warning for using `default` when every enum value was handled in the switch. Since whether the fl

[PATCH] D53274: [analyzer][NFC] Fix inconsistencies in AnalyzerOptions

2018-10-15 Thread George Karpenkov via Phabricator via cfe-commits
george.karpenkov added a comment. I'm not sure why you could get away with removing those llvm_unreachable cases? Comment at: lib/StaticAnalyzer/Core/AnalyzerOptions.cpp:373 - default: -llvm_unreachable("Invalid mode."); case UMK_Shallow: Wh

[PATCH] D53274: [analyzer][NFC] Fix inconsistencies in AnalyzerOptions

2018-10-15 Thread George Karpenkov via Phabricator via cfe-commits
george.karpenkov added a comment. > The main motivation behind here is to emit warnings if an invalid I'm totally with you here, but IIRC (@NoQ might want to correct me here), the design decision was made specifically to ignore incorrect options, so that e.g. old versions of Xcode used with old

[PATCH] D53274: [analyzer][NFC] Fix inconsistencies in AnalyzerOptions

2018-10-15 Thread Umann Kristóf via Phabricator via cfe-commits
Szelethus updated this revision to Diff 169703. https://reviews.llvm.org/D53274 Files: include/clang/StaticAnalyzer/Core/AnalyzerOptions.h lib/StaticAnalyzer/Core/AnalyzerOptions.cpp lib/StaticAnalyzer/Core/CoreEngine.cpp Index: lib/StaticAnalyzer/Core/CoreEngine.cpp ==