diff --git a/compiler/src/dmd/dsymbolsem.d b/compiler/src/dmd/dsymbolsem.d index 9d152061ff51..686b8b404c8f 100644 --- a/compiler/src/dmd/dsymbolsem.d +++ b/compiler/src/dmd/dsymbolsem.d @@ -1494,14 +1494,6 @@ private extern(C++) final class DsymbolSemanticVisitor : Visitor if (dsym.errors) return; - if (!(global.params.bitfields || sc.flags & SCOPE.Cfile)) - { - version (IN_GCC) - .error(dsym.loc, "%s `%s` use `-fpreview=bitfields` for bitfield support", dsym.kind, dsym.toPrettyChars); - else - .error(dsym.loc, "%s `%s` use -preview=bitfields for bitfield support", dsym.kind, dsym.toPrettyChars); - } - if (!dsym.parent.isStructDeclaration() && !dsym.parent.isClassDeclaration()) { .error(dsym.loc, "%s `%s` - bit-field must be member of struct, union, or class", dsym.kind, dsym.toPrettyChars); diff --git a/compiler/test/compilable/dbitfield.d b/compiler/test/compilable/dbitfield.d index 7187c37410ec..74717061546e 100644 --- a/compiler/test/compilable/dbitfield.d +++ b/compiler/test/compilable/dbitfield.d @@ -1,4 +1,4 @@ -/* REQUIRED_ARGS: -preview=bitfields +/* */ /***************************************************/ diff --git a/compiler/test/fail_compilation/biterrors.d b/compiler/test/fail_compilation/biterrors.d index a8f0faa07392..b59107f0a284 100644 --- a/compiler/test/fail_compilation/biterrors.d +++ b/compiler/test/fail_compilation/biterrors.d @@ -1,4 +1,4 @@ -/* REQUIRED_ARGS: -preview=bitfields +/* * TEST_OUTPUT: --- fail_compilation/biterrors.d(103): Error: initializer not allowed for bit-field declaration diff --git a/compiler/test/fail_compilation/biterrors2.d b/compiler/test/fail_compilation/biterrors2.d index 77671eb853ff..d942cc3fcb7e 100644 --- a/compiler/test/fail_compilation/biterrors2.d +++ b/compiler/test/fail_compilation/biterrors2.d @@ -1,4 +1,4 @@ -/* REQUIRED_ARGS: -preview=bitfields +/* * TEST_OUTPUT: --- fail_compilation/biterrors2.d(100): Error: variable `biterrors2.a` - bit-field must be member of struct, union, or class diff --git a/compiler/test/fail_compilation/biterrors3.d b/compiler/test/fail_compilation/biterrors3.d index 09d7be66d643..6acb6f87cb18 100644 --- a/compiler/test/fail_compilation/biterrors3.d +++ b/compiler/test/fail_compilation/biterrors3.d @@ -1,4 +1,4 @@ -/* REQUIRED_ARGS: -preview=bitfields +/* * TEST_OUTPUT: --- fail_compilation/biterrors3.d(103): Error: storage class not allowed for bit-field declaration diff --git a/compiler/test/fail_compilation/biterrors4.d b/compiler/test/fail_compilation/biterrors4.d index 0f2ca2d0d3fc..99201e29f83e 100644 --- a/compiler/test/fail_compilation/biterrors4.d +++ b/compiler/test/fail_compilation/biterrors4.d @@ -1,4 +1,4 @@ -/* REQUIRED_ARGS: -preview=bitfields +/* * TEST_OUTPUT: --- fail_compilation/biterrors4.d(109): Error: cannot take address of bit-field `a` diff --git a/compiler/test/fail_compilation/dbitfields.d b/compiler/test/fail_compilation/dbitfields.d index 0dd1a0bf96e7..5d135b7bf4cb 100644 --- a/compiler/test/fail_compilation/dbitfields.d +++ b/compiler/test/fail_compilation/dbitfields.d @@ -1,4 +1,4 @@ -/* REQUIRED_ARGS: -preview=bitfields +/* * TEST_OUTPUT: --- fail_compilation/dbitfields.d(118): Error: reinterpretation through overlapped field `e` is not allowed in CTFE diff --git a/compiler/test/fail_compilation/test16188.d b/compiler/test/fail_compilation/test16188.d index 0bd052ca6db1..6584b63fc0f1 100644 --- a/compiler/test/fail_compilation/test16188.d +++ b/compiler/test/fail_compilation/test16188.d @@ -1,4 +1,4 @@ -/* REQUIRED_ARGS: -preview=bitfields +/* * TEST_OUTPUT: --- fail_compilation/test16188.d(101): Error: no property `name` for `Where()` of type `test16188.Where` diff --git a/compiler/test/fail_compilation/test17284.d b/compiler/test/fail_compilation/test17284.d index b7fd9796d8be..f2c031e0e3ee 100644 --- a/compiler/test/fail_compilation/test17284.d +++ b/compiler/test/fail_compilation/test17284.d @@ -4,7 +4,7 @@ TEST_OUTPUT: fail_compilation/test17284.d(17): Error: field `U.c` cannot access pointers in `@safe` code that overlap other fields pure nothrow @safe void(U t) --- -REQUIRED_ARGS: -preview=bitfields + */ // https://issues.dlang.org/show_bug.cgi?id=17284 diff --git a/compiler/test/runnable/bit.d b/compiler/test/runnable/bit.d index 289e1bcfbd6a..5c232081b1a6 100644 --- a/compiler/test/runnable/bit.d +++ b/compiler/test/runnable/bit.d @@ -1,4 +1,4 @@ -/* REQUIRED_ARGS: -preview=bitfields +/* */ struct T diff --git a/compiler/test/runnable/dbitfields.d b/compiler/test/runnable/dbitfields.d index aa154c7bbb21..c8ebdc8f87a4 100644 --- a/compiler/test/runnable/dbitfields.d +++ b/compiler/test/runnable/dbitfields.d @@ -1,4 +1,4 @@ -/* REQUIRED_ARGS: -preview=bitfields +/* */ struct S diff --git a/compiler/test/runnable/dbitfieldsdm.d b/compiler/test/runnable/dbitfieldsdm.d index df7762cad612..aca32a37223e 100644 --- a/compiler/test/runnable/dbitfieldsdm.d +++ b/compiler/test/runnable/dbitfieldsdm.d @@ -1,7 +1,7 @@ /* test bitfields for Digital Mars * Note that this test is for win32 only * - * REQUIRED_ARGS: -preview=bitfields + * * DISABLED: win32mscoff win64 linux freebsd osx * RUN_OUTPUT: --- diff --git a/compiler/test/runnable/dbitfieldsms.d b/compiler/test/runnable/dbitfieldsms.d index b323ce37f829..36c743e2271b 100644 --- a/compiler/test/runnable/dbitfieldsms.d +++ b/compiler/test/runnable/dbitfieldsms.d @@ -1,5 +1,5 @@ /* test bitfields for Microsoft C - * REQUIRED_ARGS: -preview=bitfields + * * DISABLED: win32 linux32 freebsd32 osx32 linux64 freebsd64 osx64 * RUN_OUTPUT: --- diff --git a/compiler/test/runnable/dbitfieldsposix32.d b/compiler/test/runnable/dbitfieldsposix32.d index 5af9b6127ea7..373580758fe2 100644 --- a/compiler/test/runnable/dbitfieldsposix32.d +++ b/compiler/test/runnable/dbitfieldsposix32.d @@ -1,5 +1,5 @@ /* test bitfields - * REQUIRED_ARGS: -preview=bitfields + * * DISABLED: win32 win64 linux64 freebsd64 osx64 * RUN_OUTPUT: --- diff --git a/compiler/test/runnable/dbitfieldsposix64.d b/compiler/test/runnable/dbitfieldsposix64.d index 4633b757245c..9039cea9631d 100644 --- a/compiler/test/runnable/dbitfieldsposix64.d +++ b/compiler/test/runnable/dbitfieldsposix64.d @@ -1,5 +1,5 @@ /* test bitfields - * REQUIRED_ARGS: -preview=bitfields + * * DISABLED: win32 win64 linux32 freebsd32 osx32 * RUN_OUTPUT: ---