================
@@ -1006,6 +1006,8 @@ static void InitializePredefinedMacros(const TargetInfo 
&TI,
   else if (LangOpts.hasDWARFExceptions() &&
            (TI.getTriple().isThumb() || TI.getTriple().isARM()))
     Builder.defineMacro("__ARM_DWARF_EH__");
+  else if (LangOpts.hasWasmExceptions() && TI.getTriple().isWasm())
+    Builder.defineMacro("__USING_WASM_EXCEPTIONS__");
----------------
sbc100 wrote:

I see the `__USING_` prefix does predate out work on Wasm exceptions so there 
is some precedent.  

I see __USING_SJLJ_EXCEPTIONS__ dating all the way back to 2009: 
2f5c75e17dc0b2df841db396de22c35b95cb7f41.   However, I don't see any other 
predefined macros using the `__USING_` prefix, so it might be worth removing it 
now before it gets even harder to remove.

Presumably it would be quite easy for downstream toolchains to switch to using 
`__WASM_EXCEPTIONS__` either before or after this change lands.. and then 
remove the manual define at some point in the future.

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

Reply via email to