Ver Fonte

Merge pull request #97727 from SlugFiller/llvm-computed-goto

Enable use of Labels as Values feature in Clang when not wrapped by GCC
Rémi Verschelde há 11 meses atrás
pai
commit
903c3bc154
1 ficheiros alterados com 1 adições e 1 exclusões
  1. 1 1
      modules/gdscript/gdscript_vm.cpp

+ 1 - 1
modules/gdscript/gdscript_vm.cpp

@@ -227,7 +227,7 @@ void (*type_init_function_table[])(Variant *) = {
 	&VariantInitializer<PackedVector4Array>::init, // PACKED_VECTOR4_ARRAY.
 	&VariantInitializer<PackedVector4Array>::init, // PACKED_VECTOR4_ARRAY.
 };
 };
 
 
-#if defined(__GNUC__)
+#if defined(__GNUC__) || defined(__clang__)
 #define OPCODES_TABLE                                    \
 #define OPCODES_TABLE                                    \
 	static const void *switch_table_ops[] = {            \
 	static const void *switch_table_ops[] = {            \
 		&&OPCODE_OPERATOR,                               \
 		&&OPCODE_OPERATOR,                               \