Side effect of this:
Fix bug where helpers in js_mirrors were specifying that name had to have type String when it could really also be a JS Symbol as well.
Fix bug where top level JS interop members using the external keyword but no @JS keyword were not implemented.
Update js_typed_interop_test.dart so it can work in DDC.
Add regression test for jsify call with native function type arguments.
BUG=
R=vsm@google.com
Review-Url: https://codereview.chromium.org/2827333003 .
Re-enable formatter test that had been disabled when someone changed type
name display for Foo<dynamic> types.
Fix bug in how type names were displayed for JS interop types.
BUG=
R=vsm@google.com
Review-Url: https://codereview.chromium.org/2789663005 .
This is an alternative to the other CL. It just uses the result of
dart.mixin instead of declaring a new class. That preserves the assumption (at least at runtime) that the mixin class directly inherits from Object.
We were also not declaring interfaces for ClassTypeAliases.
R=jmesserly@google.com
Review-Url: https://codereview.chromium.org/2783443002 .
Update all tests
Support //# multitests for better dartfmt compatibility and fewer multitest false positives
All files under tests were manually updated with
find . -iregex '.*\.dart$' -print0 | xargs -0 perl -pi -e 's/(\S\s+)\/\/\/ /$1\/\/# /'
For now both old and new styles are allowed to accommodate CO19 tests.
R=efortuna@google.com
BUG=
Review-Url: https://codereview.chromium.org/2765693002 .
Review-Url: https://codereview.chromium.org/2765893003 .
Support //# multitests for better dartfmt compatibility and fewer multitest false positives
All files under tests were manually updated with
find . -iregex '.*\.dart$' -print0 | xargs -0 perl -pi -e 's/(\S\s+)\/\/\/ /$1\/\/# /'
For now both old and new styles are allowed to accommodate CO19 tests.
R=efortuna@google.com
Review-Url: https://codereview.chromium.org/2765693002 .
fixes#27625, Object constraints were not tracked in inference
fixes#27933, pin return type from downwards inference
We now prefer to pick the bound (lower or upper) that had some information on, and it also improves inference error messages somewhat (still a ways to go).
The way this works is we now have a type representing an unknown type: ?. We use ? when performing downward inference steps, instead of `dynamic`. This allows more accurate tracking of type constraints.
For example: given:
var x = await Future.wait([a, b]);
Future.wait<T>'s argument type is Iterable<Future<T>>. Since we didn't know T, we previously pushed down Iterable<Future<dynamic>>. The dynamic caused loss of information. Now we push down Iterable<Future<?>>, allowing us to infer the right type there.
R=leafp@google.com, vsm@google.com
Review-Url: https://codereview.chromium.org/2456803004 .
In DDC, if the receiver is typed and the target method simply forwards to a JS call, invoke that call directly instead of via a symbol.
This is a step toward #28307.
Paul: can you look the the analyzer / summary code change?
dart:html uses "native". other libraries (e.g., typed_data) use "external" for more or less the same thing. The analyzer element model doesn't provide a way to test for "native" methods, but it does for "external". I map native to external here. Not sure if it's better to treat them as separate (I believe native predated external). Longer term, it may make sense to try to remove "native" in favor of "external".
R=brianwilkerson@google.com, jacobr@google.com, jmesserly@google.com, paulberry@google.com
Review-Url: https://codereview.chromium.org/2748713002 .
Our internal tooling is complaining about this when building / checking the ddc sdk. It appears to use the analyzer's summary builder tool which seems less forgiving about dangling references / missing files.
R=srawlins@google.com
Review-Url: https://codereview.chromium.org/2740573003 .
There's some changes in strong mode errors we may want to follow up on.
Unforks the following: async, collection, convert, core, developer, internal, io, isolate, math, mirrors.
Does not unfork: html, indexed_db, js, js_util, svg, typed_data, web_audio, web_gl, web_sql.
R=vsm@google.com
Review-Url: https://codereview.chromium.org/2698353003 .