Liam Appelbe
87b829bacd
[nnbd] Fix some more strong mode tests
...
All these tests now pass in both weak and strong mode, except for
relation_subclass_test and typedef_reflected_type_test. For those 2
tests I fixed the compile time error and now they have the same runtime
errors in both weak and strong mode (they were already failing at
runtime in weak mode).
Change-Id: If0157f811fffcf72a12ce6690ac0568c8f4419a9
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/144343
Commit-Queue: Liam Appelbe <liama@google.com >
Reviewed-by: Régis Crelier <regis@google.com >
Reviewed-by: Alexander Markov <alexmarkov@google.com >
2020-04-22 00:12:24 +00:00
Konstantin Shcheglov
23a8788f6a
Issue 41378. Update on-catch and throw for the spec changes.
...
Now it is not an error to use a potentially nullable type in on-catch.
But it is an error for throw an expression of type that is not
assignable to Object.
Bug: https://github.com/dart-lang/sdk/issues/41378
Change-Id: If0a198ae618cd01d03f45a46aa1efa6179df76ee
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/143220
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
2020-04-11 20:08:03 +00:00
Leaf Petersen
b135aab6d7
Fix bad test expectation, convert to static error test
...
Change-Id: I821dd3af8c1be346d983bd41bb80efefba176cd5
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/143102
Auto-Submit: Leaf Petersen <leafp@google.com >
Reviewed-by: Bob Nystrom <rnystrom@google.com >
Commit-Queue: Bob Nystrom <rnystrom@google.com >
2020-04-10 18:07:44 +00:00
Konstantin Shcheglov
4a5e6e649a
Update default_list_constructor_test to reflect that any use of the default List constructor is an error.
...
Change-Id: I97657eb8c44fd07c4940b757d6962534b8276e36
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/140766
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-03-24 20:01:55 +00:00
Liam Appelbe
ba9e4116ab
[testing] Fix unchecked_use_of_nullable_test
...
typeParametersNullableBounds and typeParametersNullableUses are never
invoked, so can't generate runtime errors.
Bug: https://github.com/dart-lang/sdk/issues/39755
Change-Id: If1b17264c0376d0046851553e3ab282926c97da2
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/129201
Reviewed-by: Leaf Petersen <leafp@google.com >
Commit-Queue: Liam Appelbe <liama@google.com >
2019-12-20 16:40:20 +00:00
Konstantin Shcheglov
d321f6e452
Issue 39773. Don't report MISSING_DEFAULT_VALUE_FOR_PARAMETER when no default value is allowed.
...
This partially reverts https://dart-review.googlesource.com/c/sdk/+/126801
Bug: https://github.com/dart-lang/sdk/issues/39773
Change-Id: Ib147ed770d9bf328dd7792a37a72291070411964
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/129142
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
2019-12-19 23:35:13 +00:00
Leaf Petersen
e50d98cd56
Fix some incorrect NNBD tests.
...
Closes https://github.com/dart-lang/sdk/issues/39814
Closes https://github.com/dart-lang/sdk/issues/39823
Closes https://github.com/dart-lang/sdk/issues/39816
Change-Id: I5015d5cb43b27a555360423cc9567c5880c948e3
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/128777
Reviewed-by: Erik Ernst <eernst@google.com >
2019-12-19 18:43:03 +00:00
Konstantin Shcheglov
6c99171686
Report CompileTimeErrorCode.EXPORT_LEGACY_SYMBOL
...
Change-Id: Icd43121a4d7f20fdecc1bff8ced6b9378ce94149
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/128377
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
2019-12-14 01:14:55 +00:00
Robert Nystrom
3455133d98
Move NNBD tests (language_2/nnbd) to new NNBD test directory.
...
Change-Id: I0765a1e0fb19f38d7ad1c8655ba444f2f46fbf6a
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/128301
Reviewed-by: Paul Berry <paulberry@google.com >
Reviewed-by: Siva Annamalai <asiva@google.com >
Commit-Queue: Bob Nystrom <rnystrom@google.com >
2019-12-12 22:52:31 +00:00