Skip to content

Commit 9fd4a25

Browse files
author
Aidan
committed
Added c_fixed_enum as an extension. Cleaned up enum.c
1 parent d9e0615 commit 9fd4a25

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

clang/include/clang/Basic/Features.def

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,6 @@ FEATURE(objc_arc_fields, true)
131131
FEATURE(objc_arc_weak, LangOpts.ObjCWeak)
132132
FEATURE(objc_default_synthesize_properties, LangOpts.ObjC)
133133
FEATURE(objc_fixed_enum, LangOpts.ObjC)
134-
FEATURE(c_fixed_enum, true)
135134
FEATURE(objc_instancetype, LangOpts.ObjC)
136135
FEATURE(objc_kindof, LangOpts.ObjC)
137136
FEATURE(objc_modules, LangOpts.ObjC && LangOpts.Modules)
@@ -309,6 +308,10 @@ EXTENSION(datasizeof, LangOpts.CPlusPlus)
309308

310309
FEATURE(cxx_abi_relative_vtable, LangOpts.CPlusPlus && LangOpts.RelativeCXXABIVTables)
311310

311+
//Fixed enum feature and extension, to be relocated in this file
312+
FEATURE(c_fixed_enum, true)
313+
EXTENSION(c_fixed_enum, true)
314+
312315
// CUDA/HIP Features
313316
FEATURE(cuda_noinline_keyword, LangOpts.CUDA)
314317
EXTENSION(cuda_implicit_host_device_templates, LangOpts.CUDA && LangOpts.OffloadImplicitHostDeviceTemplates)

clang/test/Sema/enum.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -185,7 +185,6 @@ enum IncOverflow {
185185
V3 // pre-c23-warning {{incremented enumerator value which exceeds the range of 'int' is a C23 extension}}
186186
};
187187

188-
189188
#if __STDC_VERSION__ >= 202311L
190189
// FIXME: GCC picks __uint128_t as the underlying type for the enumeration
191190
// value and Clang picks unsigned long long.

0 commit comments

Comments
 (0)