#1285. Roll failures fixed, issue numbers added
diff --git a/LanguageFeatures/Enhanced-Enum/semantics_A06_t03.dart b/LanguageFeatures/Enhanced-Enum/semantics_A06_t03.dart
index 457697f..e9c6997 100644
--- a/LanguageFeatures/Enhanced-Enum/semantics_A06_t03.dart
+++ b/LanguageFeatures/Enhanced-Enum/semantics_A06_t03.dart
@@ -36,7 +36,7 @@
e1<int, String>(1, "1"),
e2<int, int>(2, 3);
- const E1(this.i, this.s);
+ const E1(this.t1, this.t2);
final T1 t1;
final T2 t2;
@@ -52,8 +52,4 @@
Expect.equals(1, E1.e2.index);
Expect.equals("e1", EnumName(E1.e1).name);
Expect.equals("e2", EnumName(E1.e2).name);
- Expect.equals(0, E2.e1.index);
- Expect.equals(1, E2.e2.index);
- Expect.equals("e1", EnumName(E2.e1).name);
- Expect.equals("e2", EnumName(E2.e2).name);
}
diff --git a/LanguageFeatures/Enhanced-Enum/semantics_A06_t07.dart b/LanguageFeatures/Enhanced-Enum/semantics_A06_t07.dart
index 9235b11..a73e559 100644
--- a/LanguageFeatures/Enhanced-Enum/semantics_A06_t07.dart
+++ b/LanguageFeatures/Enhanced-Enum/semantics_A06_t07.dart
@@ -28,6 +28,8 @@
/// @description Check that it is a compile-time error if args are not
/// compile-time constants
/// @author sgrekhov@unipro.ru
+/// @issue 48292
+/// @issue 48293
// SharedOptions=--enable-experiment=enhanced-enums
diff --git a/LanguageFeatures/Enhanced-Enum/semantics_A09_t01.dart b/LanguageFeatures/Enhanced-Enum/semantics_A09_t01.dart
index 3ee2df8..84027df 100644
--- a/LanguageFeatures/Enhanced-Enum/semantics_A09_t01.dart
+++ b/LanguageFeatures/Enhanced-Enum/semantics_A09_t01.dart
@@ -9,6 +9,7 @@
/// @description Check that if the resulting class would have any naming
/// conflicts then compile-time error occurs.
/// @author sgrekhov@unipro.ru
+/// @issue 48289
// SharedOptions=--enable-experiment=enhanced-enums
@@ -30,7 +31,7 @@
const E2(T t);
- final List<E2> values = [e1, e2, e3];
+ final List<E2> values = const [e1, e2, e3];
// ^^^^^^
// [analyzer] unspecified
// [cfe] unspecified
diff --git a/LanguageFeatures/Enhanced-Enum/semantics_A09_t02.dart b/LanguageFeatures/Enhanced-Enum/semantics_A09_t02.dart
index 8a57bc7..451ce52 100644
--- a/LanguageFeatures/Enhanced-Enum/semantics_A09_t02.dart
+++ b/LanguageFeatures/Enhanced-Enum/semantics_A09_t02.dart
@@ -13,6 +13,8 @@
/// @description Check that it is a compile-time error to declare any member
/// with the same basename as enum value which is not a static setter
/// @author sgrekhov@unipro.ru
+/// @issue 48290
+/// @issue 48293
// SharedOptions=--enable-experiment=enhanced-enums
@@ -33,7 +35,7 @@
e3<bool>(false);
const E2(T t);
- final List<E2> e2 = [];
+ final List<E2> e2 = const [];
// ^^
// [analyzer] unspecified
// [cfe] unspecified
diff --git a/LanguageFeatures/Enhanced-Enum/semantics_A09_t03.dart b/LanguageFeatures/Enhanced-Enum/semantics_A09_t03.dart
index 7fda9f6..fb42bf9 100644
--- a/LanguageFeatures/Enhanced-Enum/semantics_A09_t03.dart
+++ b/LanguageFeatures/Enhanced-Enum/semantics_A09_t03.dart
@@ -13,6 +13,8 @@
/// @description Check that it is a compile-time error to declare any member
/// with the same basename as enum value which is not a static setter
/// @author sgrekhov@unipro.ru
+/// @issue 48290
+/// @issue 48293
// SharedOptions=--enable-experiment=enhanced-enums
diff --git a/LanguageFeatures/Enhanced-Enum/semantics_A09_t04.dart b/LanguageFeatures/Enhanced-Enum/semantics_A09_t04.dart
index 187a315..a3eebec 100644
--- a/LanguageFeatures/Enhanced-Enum/semantics_A09_t04.dart
+++ b/LanguageFeatures/Enhanced-Enum/semantics_A09_t04.dart
@@ -13,6 +13,8 @@
/// @description Check that it is a compile-time error to declare any member
/// with the same basename as enum value which is not a static setter
/// @author sgrekhov@unipro.ru
+/// @issue 48290
+/// @issue 48294
// SharedOptions=--enable-experiment=enhanced-enums
@@ -45,7 +47,7 @@
e3;
static int get e1 => 42;
-// ^^
+// ^^
// [analyzer] unspecified
// [cfe] unspecified
}
diff --git a/LanguageFeatures/Enhanced-Enum/semantics_A09_t05.dart b/LanguageFeatures/Enhanced-Enum/semantics_A09_t05.dart
index cec8014..6a83e3b 100644
--- a/LanguageFeatures/Enhanced-Enum/semantics_A09_t05.dart
+++ b/LanguageFeatures/Enhanced-Enum/semantics_A09_t05.dart
@@ -11,8 +11,11 @@
/// setter. (The introduced static declarations would have a conflict.)
///
/// @description Check that it is a compile-time error to declare any member
-/// with the same basename as enum value which is not a static setter
+/// with the same basename as enum value which is not a static setter (or static
+/// setter has a wrong type)
/// @author sgrekhov@unipro.ru
+/// @issue 48293
+/// @issue 48295
// SharedOptions=--enable-experiment=enhanced-enums
@@ -21,7 +24,7 @@
e2,
e3;
- void set e1(int v) {};
+ void set e1(int v) {}
// ^^
// [analyzer] unspecified
// [cfe] unspecified
diff --git a/LanguageFeatures/Enhanced-Enum/semantics_A09_t06.dart b/LanguageFeatures/Enhanced-Enum/semantics_A09_t06.dart
index 331f312..2d40646 100644
--- a/LanguageFeatures/Enhanced-Enum/semantics_A09_t06.dart
+++ b/LanguageFeatures/Enhanced-Enum/semantics_A09_t06.dart
@@ -13,6 +13,8 @@
/// @description Check that it is a compile-time error to declare any member
/// with the same basename as enum value which is not a static setter
/// @author sgrekhov@unipro.ru
+/// @issue 48294
+/// @issue 48295
// SharedOptions=--enable-experiment=enhanced-enums
@@ -21,7 +23,7 @@
e2,
e3;
- void e1() {};
+ void e1() {}
// ^^
// [analyzer] unspecified
// [cfe] unspecified
diff --git a/LanguageFeatures/Enhanced-Enum/semantics_A09_t08.dart b/LanguageFeatures/Enhanced-Enum/semantics_A09_t08.dart
index 3a2da17..ce38128 100644
--- a/LanguageFeatures/Enhanced-Enum/semantics_A09_t08.dart
+++ b/LanguageFeatures/Enhanced-Enum/semantics_A09_t08.dart
@@ -13,6 +13,7 @@
/// @description Check that it is a compile-time error to inherit any member
/// with the same basename as enum value
/// @author sgrekhov@unipro.ru
+/// @issue 48295
// SharedOptions=--enable-experiment=enhanced-enums
@@ -20,10 +21,6 @@
int e1() => 42;
}
-mixin M2 on Enum {
- final int e1 = 42;
-}
-
mixin M3 on Enum {
int get e1 => 42;
}
@@ -41,15 +38,6 @@
e3;
}
-enum E2 with M2 {
- e1,
-//^^
-// [analyzer] unspecified
-// [cfe] unspecified
- e2,
- e3;
-}
-
enum E3 with M3 {
e1,
//^^
@@ -70,7 +58,6 @@
main() {
E1.e1;
- E2.e1;
E3.e1;
E4.e1;
}
diff --git a/LanguageFeatures/Enhanced-Enum/semantics_A09_t09.dart b/LanguageFeatures/Enhanced-Enum/semantics_A09_t09.dart
index b83fb6f..21e20a7 100644
--- a/LanguageFeatures/Enhanced-Enum/semantics_A09_t09.dart
+++ b/LanguageFeatures/Enhanced-Enum/semantics_A09_t09.dart
@@ -13,6 +13,7 @@
/// @description Check that it is a compile-time error to inherit any member
/// with the same basename as enum value
/// @author sgrekhov@unipro.ru
+/// @issue 48295
// SharedOptions=--enable-experiment=enhanced-enums
@@ -68,6 +69,9 @@
}
enum E4 implements I4 {
+// ^^
+// [analyzer] unspecified
+// [cfe] unspecified
e1,
//^^
// [analyzer] unspecified
diff --git a/LanguageFeatures/Enhanced-Enum/semantics_A09_t10.dart b/LanguageFeatures/Enhanced-Enum/semantics_A09_t10.dart
index 14a6082..b4932d2 100644
--- a/LanguageFeatures/Enhanced-Enum/semantics_A09_t10.dart
+++ b/LanguageFeatures/Enhanced-Enum/semantics_A09_t10.dart
@@ -13,6 +13,7 @@
/// @description Check that it is not a compile-time error to declare static
/// setter with the same basename as enum value
/// @author sgrekhov@unipro.ru
+/// @issue 48297
// SharedOptions=--enable-experiment=enhanced-enums
@@ -49,5 +50,5 @@
E1.e1 = E1.e2;
E2.e1 = E2.e1;
E2.e2 = E2.e2;
- E3.e3 = E2.e3;
+ E2.e3 = E2.e3;
}
diff --git a/LanguageFeatures/Enhanced-Enum/semantics_A09_t11.dart b/LanguageFeatures/Enhanced-Enum/semantics_A09_t11.dart
index 2166ceb..bf02c15 100644
--- a/LanguageFeatures/Enhanced-Enum/semantics_A09_t11.dart
+++ b/LanguageFeatures/Enhanced-Enum/semantics_A09_t11.dart
@@ -13,6 +13,8 @@
/// @description Check that it is a compile-time error to declare static
/// setter with the same basename as enum value but wrong type
/// @author sgrekhov@unipro.ru
+/// @issue 48293
+/// @issue 48296
// SharedOptions=--enable-experiment=enhanced-enums
@@ -51,5 +53,5 @@
E1.e1;
E2.e1;
E2.e2;
- E3.e3;
+ E2.e3;
}
diff --git a/LanguageFeatures/Enhanced-Enum/semantics_A10_t01.dart b/LanguageFeatures/Enhanced-Enum/semantics_A10_t01.dart
index ca3ab6a..7e29d92 100644
--- a/LanguageFeatures/Enhanced-Enum/semantics_A10_t01.dart
+++ b/LanguageFeatures/Enhanced-Enum/semantics_A10_t01.dart
@@ -13,6 +13,7 @@
/// @description Check that it is a compile-time error to declare a member which
/// is not a valid override of a super-interface member declaration
/// @author sgrekhov@unipro.ru
+/// @issue 48290
// SharedOptions=--enable-experiment=enhanced-enums
diff --git a/LanguageFeatures/Enhanced-Enum/semantics_A10_t02.dart b/LanguageFeatures/Enhanced-Enum/semantics_A10_t02.dart
index ee23872..56e27e0 100644
--- a/LanguageFeatures/Enhanced-Enum/semantics_A10_t02.dart
+++ b/LanguageFeatures/Enhanced-Enum/semantics_A10_t02.dart
@@ -13,6 +13,7 @@
/// @description Check that it is a compile-time error to declare a member which
/// is not a valid override of a super-interface member declaration
/// @author sgrekhov@unipro.ru
+/// @issue 48290
// SharedOptions=--enable-experiment=enhanced-enums
diff --git a/LanguageFeatures/Enhanced-Enum/semantics_A10_t03.dart b/LanguageFeatures/Enhanced-Enum/semantics_A10_t03.dart
index bdcb100..f041bd4 100644
--- a/LanguageFeatures/Enhanced-Enum/semantics_A10_t03.dart
+++ b/LanguageFeatures/Enhanced-Enum/semantics_A10_t03.dart
@@ -13,6 +13,7 @@
/// @description Check that it is a compile-time error to mixin a member which
/// is not a valid override of a super-interface member declaration
/// @author sgrekhov@unipro.ru
+/// @issue 48298
// SharedOptions=--enable-experiment=enhanced-enums
diff --git a/LanguageFeatures/Enhanced-Enum/semantics_A10_t04.dart b/LanguageFeatures/Enhanced-Enum/semantics_A10_t04.dart
index 675c2b1..78953af 100644
--- a/LanguageFeatures/Enhanced-Enum/semantics_A10_t04.dart
+++ b/LanguageFeatures/Enhanced-Enum/semantics_A10_t04.dart
@@ -13,6 +13,7 @@
/// @description Check that it is a compile-time error to declare a member which
/// is not a valid override of a super-interface member declaration
/// @author sgrekhov@unipro.ru
+/// @issue 48290
// SharedOptions=--enable-experiment=enhanced-enums
diff --git a/LanguageFeatures/Enhanced-Enum/semantics_A10_t05.dart b/LanguageFeatures/Enhanced-Enum/semantics_A10_t05.dart
index 98bdf85..f92679e 100644
--- a/LanguageFeatures/Enhanced-Enum/semantics_A10_t05.dart
+++ b/LanguageFeatures/Enhanced-Enum/semantics_A10_t05.dart
@@ -13,6 +13,7 @@
/// @description Check that it is no compile-time error to declare a member
/// which is a valid override of a super-interface member declaration
/// @author sgrekhov@unipro.ru
+/// @issue 48299
// SharedOptions=--enable-experiment=enhanced-enums
diff --git a/LanguageFeatures/Enhanced-Enum/semantics_A11_t01.dart b/LanguageFeatures/Enhanced-Enum/semantics_A11_t01.dart
index 4cb5d5e..79f6eca 100644
--- a/LanguageFeatures/Enhanced-Enum/semantics_A11_t01.dart
+++ b/LanguageFeatures/Enhanced-Enum/semantics_A11_t01.dart
@@ -13,6 +13,7 @@
/// @description Check that it is a compile-time error to declare a member
/// signature with no corresponding implementation
/// @author sgrekhov@unipro.ru
+/// @issue 48291
// SharedOptions=--enable-experiment=enhanced-enums
@@ -38,7 +39,7 @@
const E2(T t);
- String toString();
+ String toString([int index]);
// ^^^^^^^^
// [analyzer] unspecified
// [cfe] unspecified
diff --git a/LanguageFeatures/Enhanced-Enum/semantics_A11_t02.dart b/LanguageFeatures/Enhanced-Enum/semantics_A11_t02.dart
index bf2d456..61f8af4 100644
--- a/LanguageFeatures/Enhanced-Enum/semantics_A11_t02.dart
+++ b/LanguageFeatures/Enhanced-Enum/semantics_A11_t02.dart
@@ -13,6 +13,7 @@
/// @description Check that it is a compile-time error to inherit a member
/// signature with no corresponding implementation
/// @author sgrekhov@unipro.ru
+/// @issue 48291
// SharedOptions=--enable-experiment=enhanced-enums
diff --git a/LanguageFeatures/Enhanced-Enum/semantics_A11_t03.dart b/LanguageFeatures/Enhanced-Enum/semantics_A11_t03.dart
index 05de5c4..f3b4378 100644
--- a/LanguageFeatures/Enhanced-Enum/semantics_A11_t03.dart
+++ b/LanguageFeatures/Enhanced-Enum/semantics_A11_t03.dart
@@ -13,6 +13,7 @@
/// @description Check that it is a compile-time error to inherit a member
/// signature with no corresponding implementation
/// @author sgrekhov@unipro.ru
+/// @issue 48291
// SharedOptions=--enable-experiment=enhanced-enums
diff --git a/LanguageFeatures/Enhanced-Enum/semantics_A12_t01.dart b/LanguageFeatures/Enhanced-Enum/semantics_A12_t01.dart
index d18e14b..a6c86cf 100644
--- a/LanguageFeatures/Enhanced-Enum/semantics_A12_t01.dart
+++ b/LanguageFeatures/Enhanced-Enum/semantics_A12_t01.dart
@@ -13,20 +13,19 @@
/// instantiate-to-bounds result which is at least super-bounded, and a value
/// declaration may require a well-bounded instantiation).
///
-/// @description Check that it is a compile-time error to declare a type
-/// parameter on the enum which does not have a valid well-bounded result
+/// @description Check that it is not a compile-time error to declare a type
+/// parameter on the enum which does have a valid well-bounded result
/// @author sgrekhov@unipro.ru
// SharedOptions=--enable-experiment=enhanced-enums
enum E<T extends List> {
- e1<List<int>>([42]),
- e2<List<Null>>([null]);
+ e1<List<int>>(const [42]),
+ e2<List<Null>>(const [null]);
- const E2(T t);
+ const E(T t);
}
main() {
- E1.e1;
- E2.e1;
+ E.e1;
}
diff --git a/LanguageFeatures/Enhanced-Enum/semantics_A13_t01.dart b/LanguageFeatures/Enhanced-Enum/semantics_A13_t01.dart
deleted file mode 100644
index d6ba6a0..0000000
--- a/LanguageFeatures/Enhanced-Enum/semantics_A13_t01.dart
+++ /dev/null
@@ -1,57 +0,0 @@
-// Copyright (c) 2022, the Dart project authors. Please see the AUTHORS file
-// for details. All rights reserved. Use of this source code is governed by a
-// BSD-style license that can be found in the LICENSE file.
-
-/// @assertion If the resulting class would have any naming conflicts, or other
-/// compile-time errors, the enum declaration is invalid and a compile-time
-/// error occurs. Such errors include, but are not limited to:
-/// ...
-/// The type parameters of the enum not having a well-bounded
-/// instantiate-to-bounds result and an enum element omitting the type arguments
-/// and not having arguments which valid type arguments can be inferred from
-/// (because an implicit EnumName(0, "foo", unrelatedArgs) constructor
-/// invocation requires a well-bound inferred type arguments for a generic
-/// EnumName enum)..
-///
-/// @description Check that it is a compile-time error to declare a ...
-/// @author sgrekhov@unipro.ru
-
-// SharedOptions=--enable-experiment=enhanced-enums
-
-enum E1 {
- e1,
- e2,
- e3;
-
- String toString([int index]);
-// ^^^^^^^^
-// [analyzer] unspecified
-// [cfe] unspecified
- void foo();
-// ^^^
-// [analyzer] unspecified
-// [cfe] unspecified
-}
-
-enum E2<T> {
- e1<int>(42),
- e2<String>("42"),
- e3<bool>(false);
-
- const E2(T t);
-
- String toString();
-// ^^^^^^^^
-// [analyzer] unspecified
-// [cfe] unspecified
-
- void foo();
-// ^^^
-// [analyzer] unspecified
-// [cfe] unspecified
-}
-
-main() {
- E1.e1;
- E2.e1;
-}
diff --git a/LanguageFeatures/Enhanced-Enum/semantics_A14_t01.dart b/LanguageFeatures/Enhanced-Enum/semantics_A14_t01.dart
index aed434b..f5487ee 100644
--- a/LanguageFeatures/Enhanced-Enum/semantics_A14_t01.dart
+++ b/LanguageFeatures/Enhanced-Enum/semantics_A14_t01.dart
@@ -11,6 +11,8 @@
/// @description Check that it is a compile-time error if non-constant value is
/// used as argument of an enum value
/// @author sgrekhov@unipro.ru
+/// @issue 48292
+/// @issue 48293
// SharedOptions=--enable-experiment=enhanced-enums
diff --git a/LanguageFeatures/Enhanced-Enum/semantics_A15_t01.dart b/LanguageFeatures/Enhanced-Enum/semantics_A15_t01.dart
index 2e332a2..a782e29 100644
--- a/LanguageFeatures/Enhanced-Enum/semantics_A15_t01.dart
+++ b/LanguageFeatures/Enhanced-Enum/semantics_A15_t01.dart
@@ -12,6 +12,7 @@
/// @description Check that it is a compile-time error to declare a static
/// member and inheriting an instance member with the same base-name.
/// @author sgrekhov@unipro.ru
+/// @issue 48290
// SharedOptions=--enable-experiment=enhanced-enums