ziqingluo-90 added inline comments.
================ Comment at: clang/lib/Analysis/UnsafeBufferUsage.cpp:543 #define GADGET(x) \ - x ## Gadget::matcher().bind(#x), + allOf(x ## Gadget::matcher().bind(#x), notInSafeBufferOptOut()), #include "clang/Analysis/Analyses/UnsafeBufferUsageGadgets.def" ---------------- ziqingluo-90 wrote: > NoQ wrote: > > This prevents safe fixable gadgets from being found in the opt-out zone. I > > think this clause should only apply to warning gadgets. > You are right! Fixables should be found regardless of whether they are in an > opt-out zone. A Fixable could later be immediately discarded once we know > that the variable declaration associated to the Fixable is in an opt-out zone. Oh wait, scratch what I said above. `FixableGadget`s should be found regardless of whether they are in an opt-out zone. They will be attached to variable declarations. The emission of an Unsafe Buffer diagnostic of a variable declaration only depends on `WarningGadget`s. So `FixableGadget`s have nothing to do with opt-out regions. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D140179/new/ https://reviews.llvm.org/D140179 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits