Skip to content

Commit 0360930

Browse files
parloughCommit Queue
authored and
Commit Queue
committed
[changelog] Add optional named parameter separator breaking change
Fixes #52491 Bug: #52491 Change-Id: Ief94acb7a3ba75ea555718e017e39ce2c418b41e Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/320020 Reviewed-by: Lasse Nielsen <[email protected]> Commit-Queue: Lasse Nielsen <[email protected]>
1 parent 80fb7b3 commit 0360930

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

CHANGELOG.md

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -342,11 +342,16 @@ constraint][language version] lower bound to 3.0 or greater (`sdk: '^3.0.0'`).
342342
declaration. If you haven't upgraded a class to Dart 3.0, you can still use it
343343
as a mixin.
344344

345-
- **Breaking Change** [#50902][]: Dart reports a compile-time error if a
345+
- **Breaking change** [#50902][]: Dart reports a compile-time error if a
346346
`continue` statement targets a [label] that is not a loop (`for`, `do` and
347347
`while` statements) or a `switch` member. Fix this by changing the `continue`
348348
to target a valid labeled statement.
349349

350+
- **Breaking change** [language/#2357][]: Starting in language version 3.0,
351+
Dart reports a compile-time error if a colon (`:`) is used as the
352+
separator before the default value of an optional named parameter.
353+
Fix this by changing the colon (`:`) to an equal sign (`=`).
354+
350355
[records]: https://dart.dev/language/records
351356
[tuples]: https://en.wikipedia.org/wiki/Tuple
352357
[pattern matching]: https://dart.dev/language/patterns
@@ -361,6 +366,7 @@ constraint][language version] lower bound to 3.0 or greater (`sdk: '^3.0.0'`).
361366
[mixin class]: https://dart.dev/language/mixins#class-mixin-or-mixin-class
362367
[#50902]: https://github.com/dart-lang/sdk/issues/50902
363368
[label]: https://dart.dev/language/branches#switch
369+
[language/#2357][]: https://github.com/dart-lang/language/issues/2357
364370

365371
### Libraries
366372

0 commit comments

Comments
 (0)