Skip to content

Commit

Permalink
dart-lang#2641. Add experimental flag to wildcards tests
Browse files Browse the repository at this point in the history
  • Loading branch information
sgrekhov committed May 8, 2024
1 parent 0b00c5e commit b0e4e08
Show file tree
Hide file tree
Showing 10 changed files with 20 additions and 0 deletions.
2 changes: 2 additions & 0 deletions LanguageFeatures/Wildcards/binding_A01_t01.dart
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@
/// scope by a wildcarded declaration. Test parameters of functions and methods.
/// @author sgrekhov22@gmail.com
// SharedOptions=--enable-experiment=wildcards

void topLevelFunction1(int _) {
print(_);
// ^
Expand Down
2 changes: 2 additions & 0 deletions LanguageFeatures/Wildcards/binding_A01_t02.dart
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@
/// scope by a wildcarded declaration. Test parameters of constructors.
/// @author sgrekhov22@gmail.com
// SharedOptions=--enable-experiment=wildcards

class C<T> {
C();
C.constructor1(int _) {
Expand Down
2 changes: 2 additions & 0 deletions LanguageFeatures/Wildcards/binding_A01_t03.dart
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@
/// scope by a wildcarded declaration. Test parameters of operators.
/// @author sgrekhov22@gmail.com
// SharedOptions=--enable-experiment=wildcards

class C {
int operator +(int _) {
print(_);
Expand Down
2 changes: 2 additions & 0 deletions LanguageFeatures/Wildcards/binding_A01_t04.dart
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@
/// scope by a wildcarded declaration. Test local variables.
/// @author sgrekhov22@gmail.com
// SharedOptions=--enable-experiment=wildcards

test1() {
var _;
print(_);
Expand Down
2 changes: 2 additions & 0 deletions LanguageFeatures/Wildcards/binding_A01_t05.dart
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@
/// scope by a wildcarded declaration. Test callable local variables.
/// @author sgrekhov22@gmail.com
// SharedOptions=--enable-experiment=wildcards

class C {}

test1() {
Expand Down
2 changes: 2 additions & 0 deletions LanguageFeatures/Wildcards/binding_A01_t06.dart
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@
/// scope by a wildcarded declaration. Test for-loop variables.
/// @author sgrekhov22@gmail.com
// SharedOptions=--enable-experiment=wildcards

test() async {
await for (var _ in Stream.fromIterable([1, 2,3])) {
print(_);
Expand Down
2 changes: 2 additions & 0 deletions LanguageFeatures/Wildcards/binding_A01_t07.dart
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@
/// scope by a wildcarded declaration. Test catch clause parameters.
/// @author sgrekhov22@gmail.com
// SharedOptions=--enable-experiment=wildcards

main() {
try {
throw "!";
Expand Down
2 changes: 2 additions & 0 deletions LanguageFeatures/Wildcards/binding_A01_t08.dart
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@
/// scope by a wildcarded declaration. Test type parameters of generic functions
/// @author sgrekhov22@gmail.com
// SharedOptions=--enable-experiment=wildcards

void topLevelFunction<_>() {
print(_);
// ^
Expand Down
2 changes: 2 additions & 0 deletions LanguageFeatures/Wildcards/binding_A01_t09.dart
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@
/// scope by a wildcarded declaration. Test type parameters of generic types.
/// @author sgrekhov22@gmail.com
// SharedOptions=--enable-experiment=wildcards

class C<_> {
void instanceMethod() {
print(_);
Expand Down
2 changes: 2 additions & 0 deletions LanguageFeatures/Wildcards/binding_A01_t10.dart
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@
/// scope by a wildcarded declaration. Test type parameters of type aliases.
/// @author sgrekhov22@gmail.com
// SharedOptions=--enable-experiment=wildcards

class C<T> {}
typedef CAlias<_> = C<_>;
// ^
Expand Down

0 comments on commit b0e4e08

Please sign in to comment.