phosek added inline comments.
================ Comment at: clang/lib/Driver/SanitizerArgs.cpp:369 // Check that LTO is enabled if we need it. if ((Kinds & NeedsLTO) && !D.isUsingLTO()) { D.Diag(diag::err_drv_argument_only_allowed_with) ---------------- vitalybuka wrote: > Is this change needed to avoid errors at "Kinds & NeedsLTO" and > KindsToDiagnose? > Could you create a test for this change? It is needed for D44065, if we enable some sanitizers like SafeStack by default, user would get an error when they enable some incompatible sanitizer like ASan and would require them passing `-fno-sanitizer=safe-stack` to avoid that error which is non-intuitive. Instead, with this change the incompatible default sanitizers are disabled automatically. Repository: rC Clang https://reviews.llvm.org/D44064 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits