MaskRay wrote: > I don't really understand the rationale for this, and it's kind of annoying. > Most of the compiler's flags behave in the "last one wins" fashion (such as > `-O2` and `-O0`) and it's always been convenient to add the flag you want at > the end. Why treat action flags any differently? Also, even if this is > worthwhile for some reason I haven't considered, why is it an error rather > than a warning?
@bogner Some action options are shared between driver and cc1 but the behaviors could be quite different. See my example in the description. ``` %clang_cc1 -S -emit-llvm a.c # -S is overridden %clang_cc1 -emit-llvm -S a.c # -emit-llvm is overridden %clang_cc1 -fsyntax-only -S a.c # -fsyntax-only is overridden ``` The strictness helps ensure that `%clang_cc1` tests do not have misleading, overridden action options. https://github.com/llvm/llvm-project/pull/91140 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits