commit | 00a28b579771f74efbcc274e3a40c5840f57820b | [log] [tgz] |
---|---|---|
author | Erik Ernst <eernst@google.com> | Thu Oct 15 21:35:41 2020 +0000 |
committer | commit-bot@chromium.org <commit-bot@chromium.org> | Thu Oct 15 21:35:41 2020 +0000 |
tree | 9b2a0862e67b84437a28908fc9fa8a5ee12f2e70 | |
parent | e02085bec354dd7264b1aaba9cb484ef2609c00b [diff] |
Fix test with syntax error This CL changes `late x;` to `late var x;` in a test. Apparently, this syntax was considered correct and the front end and analyzer accept it. However, it is a syntax error, and this CL corrects it. The fact that the tools accept it is reported as SDK issue #43811. Change-Id: Iaa2fe56fe99d3702345368a54a7389a59288515c Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/167804 Reviewed-by: Nate Bosch <nbosch@google.com> Commit-Queue: Erik Ernst <eernst@google.com>
diff --git a/tests/language/nnbd/inference/late_variable_type_for_promotion_test.dart b/tests/language/nnbd/inference/late_variable_type_for_promotion_test.dart index d6223d5..fd4ebed 100644 --- a/tests/language/nnbd/inference/late_variable_type_for_promotion_test.dart +++ b/tests/language/nnbd/inference/late_variable_type_for_promotion_test.dart
@@ -95,7 +95,7 @@ } void uninitializedUntyped() { - late x; + late var x; x = 0; x.expectStaticType<Exactly<dynamic>>(); // Attempting to promote to `int?` should be ok, since `int?` is a subtype of