mirror of
https://github.com/dart-lang/sdk
synced 2024-10-02 23:59:16 +00:00
Revise CHANGELOG.
Change-Id: I79f20a03ea7f52d436c353fd2de878f6797d1e28 Reviewed-on: https://dart-review.googlesource.com/68203 Commit-Queue: Bob Nystrom <rnystrom@google.com> Reviewed-by: Sigmund Cherem <sigmund@google.com>
This commit is contained in:
parent
91c6130b5e
commit
a19a4687f5
49
CHANGELOG.md
49
CHANGELOG.md
|
@ -9,28 +9,29 @@ significant changes across all areas of the platform. Large changes include:
|
||||||
products. Now it is the one official static type system for the entire
|
products. Now it is the one official static type system for the entire
|
||||||
platform and replaces the previous "checked" and "production" modes.
|
platform and replaces the previous "checked" and "production" modes.
|
||||||
|
|
||||||
* The `new` keyword is optional and can be omitted. Likewise, `const` can be
|
* **(Breaking)** Functions marked `async` now run synchronously until the
|
||||||
omitted inside a const context ([issue 30921][].
|
first `await` statement. Previously, they would return to the event loop
|
||||||
|
once at the top of the function body before any code runs ([issue 30345][]).
|
||||||
* **(Breaking)** Functions marked `async` now run synchronously to the first
|
|
||||||
`await` statement instead of returning to the event loop once at the top of
|
|
||||||
the function body before any code runs ([issue 30345][]).
|
|
||||||
|
|
||||||
* **(Breaking)** Constants in the core libraries have been renamed from
|
* **(Breaking)** Constants in the core libraries have been renamed from
|
||||||
`SCREAMING_CAPS` to `lowercaseWithUnderscores`.
|
`SCREAMING_CAPS` to `lowerCamelCase`.
|
||||||
|
|
||||||
* **(Breaking)** Many new methods have been added to core library classes. If
|
* **(Breaking)** Many new methods have been added to core library classes. If
|
||||||
you implement the interfaces of these classes, you will need to implement
|
you implement the interfaces of these classes, you will need to implement
|
||||||
the new methods.
|
the new methods.
|
||||||
|
|
||||||
* "dart:isolate" and "dart:mirrors" are no longer supported when using Dart
|
* **(Breaking)** "dart:isolate" and "dart:mirrors" are no longer supported
|
||||||
for the web. They are still supported in the command-line VM.
|
when using Dart for the web. They are still supported in the command-line
|
||||||
|
VM.
|
||||||
* Dartium is no longer maintained or supported.
|
|
||||||
|
|
||||||
* **(Breaking)** Pub's transformer-based build system has been [replaced by a
|
* **(Breaking)** Pub's transformer-based build system has been [replaced by a
|
||||||
new build system][transformers].
|
new build system][transformers].
|
||||||
|
|
||||||
|
* The `new` keyword is optional and can be omitted. Likewise, `const` can be
|
||||||
|
omitted inside a const context ([issue 30921][]).
|
||||||
|
|
||||||
|
* Dartium is no longer maintained or supported.
|
||||||
|
|
||||||
[issue 30345]: https://github.com/dart-lang/sdk/issues/30345
|
[issue 30345]: https://github.com/dart-lang/sdk/issues/30345
|
||||||
[issue 30921]: https://github.com/dart-lang/sdk/issues/30921
|
[issue 30921]: https://github.com/dart-lang/sdk/issues/30921
|
||||||
[strong mode]: https://www.dartlang.org/guides/language/sound-dart
|
[strong mode]: https://www.dartlang.org/guides/language/sound-dart
|
||||||
|
@ -60,8 +61,9 @@ significant changes across all areas of the platform. Large changes include:
|
||||||
to have parts, and it allows tools to easily find the library of a part
|
to have parts, and it allows tools to easily find the library of a part
|
||||||
file. The Dart 1.0 syntax is supported but deprecated.
|
file. The Dart 1.0 syntax is supported but deprecated.
|
||||||
|
|
||||||
* Added support for starting `async` functions synchronously. All tools (VM,
|
* Functions marked `async` now run synchronously until the first `await`
|
||||||
dart2js, DDC) support this ([issue 30345][]).
|
statement. Previously, they would return to the event loop once at the top
|
||||||
|
of the function body before any code runs ([issue 30345][]).
|
||||||
|
|
||||||
* The type `void` is now a Top type like `dynamic`, and `Object`. It also now
|
* The type `void` is now a Top type like `dynamic`, and `Object`. It also now
|
||||||
has new errors for being used where not allowed (such as being assigned to
|
has new errors for being used where not allowed (such as being assigned to
|
||||||
|
@ -80,9 +82,9 @@ significant changes across all areas of the platform. Large changes include:
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
* Invocations of `noSuchMethod()` receive default values for optional args. The
|
* Invocations of `noSuchMethod()` receive default values for optional args.
|
||||||
following program used to print "No arguments passed", and now prints "First
|
The following program used to print "No arguments passed", and now prints
|
||||||
argument is 3".
|
"First argument is 3".
|
||||||
|
|
||||||
```dart
|
```dart
|
||||||
abstract class B {
|
abstract class B {
|
||||||
|
@ -118,19 +120,6 @@ significant changes across all areas of the platform. Large changes include:
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
* Inference chooses `void` when combining `Object` or `dynamic` and `void`
|
|
||||||
([issue 33341][]). When combining with other top types, inference now
|
|
||||||
prefers `void`. For example, given:
|
|
||||||
|
|
||||||
```dart
|
|
||||||
void foo() {};
|
|
||||||
dynamic bar() {};
|
|
||||||
var a = [foo(), bar()];
|
|
||||||
```
|
|
||||||
|
|
||||||
The variable `a` would previously have been inferred as `List<dynamic>`, and
|
|
||||||
is now be inferred as `List<void>`.
|
|
||||||
|
|
||||||
* Numerous corner case bugs around return statements in synchronous and
|
* Numerous corner case bugs around return statements in synchronous and
|
||||||
asynchronous functions fixed. Specifically:
|
asynchronous functions fixed. Specifically:
|
||||||
|
|
||||||
|
@ -320,7 +309,7 @@ Still need entries for all changes to dart:html since 1.x
|
||||||
#### `dart:html`
|
#### `dart:html`
|
||||||
|
|
||||||
* Removed deprecated `query` and `queryAll`. Use `querySelector` and
|
* Removed deprecated `query` and `queryAll`. Use `querySelector` and
|
||||||
`queryAllSelector`.
|
`querySelectorAll`.
|
||||||
|
|
||||||
#### `dart:io`
|
#### `dart:io`
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue