[clang] [HLSL] Add NativeInt16Type langopt to control whether short type is supported. Enabled by default for all but HLSL. (PR #165584)
Justin Bogner via cfe-commits
cfe-commits at lists.llvm.org
Thu Oct 30 10:24:48 PDT 2025
================
@@ -8628,6 +8628,10 @@ def fobjc_subscripting_legacy_runtime : Flag<["-"], "fobjc-subscripting-legacy-r
def vtordisp_mode_EQ : Joined<["-"], "vtordisp-mode=">,
HelpText<"Control vtordisp placement on win32 targets">,
MarshallingInfoInt<LangOpts<"VtorDispMode">, "1">;
+def fnative_int16_type : Flag<["-"], "fnative-int16-type">,
+ HelpText<"Use 16 bit integer types">,
+ ImpliedByAnyOf<[!strconcat("!", hlsl.KeyPath)]>,
----------------
bogner wrote:
This might deserve a comment explaining that we're implying the option *unless* we're in the HLSL language mode. I don't think I've seen logical operators used inside `ImpliedByAnyOf` like this elsewhere.
https://github.com/llvm/llvm-project/pull/165584
More information about the cfe-commits
mailing list