chore(deps): update dependency dart to v3.4.0 #138
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR contains the following updates:
3.3.4
->3.4.0
Release Notes
dart-lang/sdk (dart)
v3.4.0
Compare Source
Language
Dart 3.4 makes improvements to the type analysis of conditional expressions
(
e1 ? e2 : e3
), if-null expressions (e1 ?? e2
), if-null assignments(
e1 ??= e2
), and switch expressions (switch (e) { p1 => e1, ... }
). To takeadvantage of these improvements, set your package's
SDK constraint lower bound to 3.4 or greater
(
sdk: '^3.4.0'
).Breaking Change #54640: The pattern context type schema for
cast patterns has been changed from
Object?
to_
(the unknowntype), to align with the specification. This change is not expected
to make any difference in practice.
Breaking Change #54828: The type schema used by the compiler front end
to perform type inference on the operand of a null-aware spread operator
(
...?
) in map and set literals has been made nullable, to match whatcurrently happens in list literals. This makes the compiler front end behavior
consistent with that of the analyzer. This change is expected to be very low
impact.
Libraries
dart:async
ParallelWaitError
to get some meta-information thatit can expose in its
toString
, and theIterable<Future>.wait
and(Future,...,Future).wait
extension methods now provide that information.Should make a
ParallelWaitError
easier to log.dart:cli
waitFor
is removed in 3.4.dart:ffi
Struct.create
andUnion.create
to create struct and union viewsof the sequence of bytes stored in a subtype of
TypedData
.dart:io
Breaking change #53863:
Stdout
has a new fieldlineTerminator
,which allows developers to control the line ending used by
stdout
andstderr
. Classes thatimplement Stdout
must define thelineTerminator
field. The default semantics of
stdout
andstderr
are not changed.Deprecates
FileSystemDeleteEvent.isDirectory
, which always returnsfalse
.dart:js_interop
Fixes an issue with several comparison operators in
JSAnyOperatorExtension
that were declared to return
JSBoolean
but really returnedbool
. This ledto runtime errors when trying to use the return values. The implementation now
returns a
JSBoolean
to align with the interface. See issue #55024 formore details.
Added
ExternalDartReference
and related conversion functionstoExternalReference
andtoDartObject
. This is a faster alternative toJSBoxedDartObject
, but with fewer safety guarantees and fewerinteroperability capabilities. See #55187 for more details.
On dart2wasm,
JSBoxedDartObject
now is an actual JS object that wraps theopaque Dart value instead of only externalizing the value. Like the JS
backends, you'll now get a more useful error when trying to use it in another
Dart runtime.
Added
isA
helper to make type checks easier with interop types. See#54138 for more details.
dart:typed_data
BREAKING CHANGE #53218 #53785: The unmodifiable view classes for
typed data are deprecated.
To create an unmodifiable view of a typed-data object, use the
asUnmodifiableView()
methods added in Dart 3.3:The reason for this change is to allow more flexibility in the implementation
of typed data, so the native and web platforms can use different strategies
to ensure that typed data has good performance.
The deprecated types will be removed in Dart 3.5.
Tools
Analyzer
Improved code completion. Fixed over 50% of completion correctness bugs,
tagged
analyzer-completion-correctness
in the issuetracker.
Support for new annotations introduced in version 1.14.0 of the meta
package.
Support for the [
@doNotSubmit
][@doNotSubmit] annotation, noting that any usage of anannotated member should not be submitted to source control.
Support for the [
@mustBeConst
][@mustBeConst] annotation, which indicates that anannotated parameter only accepts constant arguments.
Linter
unnecessary_library_name
][unnecessary_library_name] lint.missing_code_block_language_in_doc_comment
][missing_code_block_language_in_doc_comment] lint.Compilers
value
""
for alldart.library.foo
strings, wheredart:foo
is not anavailable library. Instead there will only be entries for the available
libraries, like
dart.library.core
, where the value was, and still is,"true"
. This should have no effect onconst bool.fromEnvironment(...)
orconst String.fromEnvironment(...)
without adefaultValue
argument, anargument which was always ignored previously. It changes the behavior of
const bool.hasEnvironment(...)
on such an input, away from always beingtrue
and therefore useless.DevTools
To learn more, check out the release notes for versions
2.32.0 and 2.33.0.
Pub
Dependency resolution and
dart pub outdated
will now surface if a dependencyis affected by a security advisory, unless the advisory is listed under a
ignored_advisories
section in thepubspec.yaml
file. To learn more aboutpub's support for security advisories, visit
dart.dev/go/pub-security-advisories.
path
-dependencies insidegit
-dependencies are now resolved relative to thegit repo.
All
dart pub
commands can now be run from any subdirectory of a project. Pubwill find the first parent directory with a
pubspec.yaml
and operaterelative it.
New command
dart pub unpack
that downloads a package from pub.dev andextracts it to a subfolder of the current directory.
This can be useful for inspecting the code, or playing with examples.
Dart Runtime
Dart VM flags and options can now be provided to any executable generated
using
dart compile exe
via theDART_VM_OPTIONS
environment variable.DART_VM_OPTIONS
should be set to a list of comma-separated flags and optionswith no whitespace. Options that allow for multiple values to be provided as
comma-separated values are not supported (e.g.,
--timeline-streams=Dart,GC,Compiler
).Example of a valid
DART_VM_OPTIONS
environment variable:Dart VM no longer supports external strings:
Dart_IsExternalString
,Dart_NewExternalLatin1String
andDart_NewExternalUTF16String
functions areremoved from Dart C API.
Configuration
📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).
🚦 Automerge: Enabled.
♻ Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.
This PR has been generated by Mend Renovate. View repository job log here.