Commit Graph

4 Commits

Author SHA1 Message Date
Chloe Stefantsova 6e1ba9d773 [cfe] Error on variable use before declaration, not on declaration
Closes https://github.com/dart-lang/sdk/issues/53422

Change-Id: Ia3d138acf870533c88be2dd81cc4079176b2fec7
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/329101
Commit-Queue: Chloe Stefantsova <cstefantsova@google.com>
Reviewed-by: Johnni Winther <johnniwinther@google.com>
2023-10-03 10:51:15 +00:00
Robert Nystrom 924b9f55ba Migrate "l" and "m" directory language tests off @compile-error.
The "@compile-error" comment is an old not-great way of defining static
error tests.

Also fix a test to use a mixin declaration instead of a class for declaring a mixin. This was
broken by class modifiers but the breakage was masked by @compile-error treating a test as
passing if any compile error, even an unrelated one, is reported.

See: https://github.com/dart-lang/sdk/issues/45634
Change-Id: I5d1d387002d886cb87340e2559bf8ed01c3f2d6a
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/296409
Commit-Queue: Bob Nystrom <rnystrom@google.com>
Auto-Submit: Bob Nystrom <rnystrom@google.com>
Reviewed-by: Nate Bosch <nbosch@google.com>
2023-04-20 17:51:42 +00:00
Ahmed Ashour 49c7d93042 [cfe/analyzer] add CompileTimeErrorCode.CONTINUE_LABEL_INVALID
Fixes #49852

Change-Id: Ic4d475d383dba51ad438de5ef7f928ce5d105e12
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/277481
Reviewed-by: Johnni Winther <johnniwinther@google.com>
Reviewed-by: Paul Berry <paulberry@google.com>
Commit-Queue: Johnni Winther <johnniwinther@google.com>
2023-01-18 19:10:46 +00:00
Robert Nystrom 3218ba8412 Migrate language_2/loop to NNBD.
Change-Id: Id8fee2221036b8dca12675ba3e4fc1c0ab7a09b7
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/149393
Auto-Submit: Bob Nystrom <rnystrom@google.com>
Reviewed-by: Srujan Gaddam <srujzs@google.com>
Commit-Queue: Bob Nystrom <rnystrom@google.com>
2020-05-29 23:48:57 +00:00