https://github.com/erichkeane commented:

I also have done this a ton, but it is something we need to leave legal, as it 
IS a pattern folks actually use intentionally.  So making this an error isn't 
something we can really do.

Doing this as a visitor is, IMO, not the right solution here. We can actually 
do this via https://clang.llvm.org/doxygen/classclang_1_1Scope.html I think 
instead?  I wonder if anyone else has better ideas, but a visitor on every 
variable reference inside of an else is not acceptable.

https://github.com/llvm/llvm-project/pull/156436
_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to