Jacob Richman
0dbb32f406
Run formatter on dev_compiler.
...
BUG=
R=vsm@google.com
Review-Url: https://codereview.chromium.org/2830503002 .
2017-04-18 16:16:14 -07:00
Jacob Richman
b280a7803d
Dev compiler debugger related tweaks.
...
Optimize dynamic call tracking using random sampling.
Apply source maps to improve dynamic call tracking accuracy.
Dynamic calls within the sdk are now attributed correctly.
Fix bug formatting modules where we were incorrectly flagging them as JS.
BUG=
R=jmesserly@google.com , vsm@google.com
Review-Url: https://codereview.chromium.org/2811343002 .
2017-04-17 14:57:31 -07:00
Zachary Anderson
9ce608e89d
[dart:io] Adds ProcessInfo.{max,current}Rss. Adds OS::MaxRSS on Fuchsia.
...
R=rmacnak@google.com
Review-Url: https://codereview.chromium.org/2822943002 .
2017-04-17 14:41:40 -07:00
Ben Konyi
6fbdd19ddb
Various fixes for sync socket implementation.
...
Revert "Revert "Added sync_socket.h include in sync_socket_win.cc""
This reverts commit 2bd6168e1ebf35f6dbd9b2724339362c493377fc.
Revert "Revert "Added synchronous socket implementation to dart:io.""
This reverts commit a47bce03f5502dac7fb12e777e87b5aa1cfc830b.
BUG=
R=zra@google.com
Review-Url: https://codereview.chromium.org/2814773004 .
2017-04-12 14:20:48 -07:00
Ben Konyi
b439bd9a54
Revert "Added synchronous socket implementation to dart:io."
...
This reverts commit a1f87ebdb8 .
Revert "Added sync_socket.h include in sync_socket_win.cc"
This reverts commit bdec13e865 .
BUG=
Review-Url: https://codereview.chromium.org/2812153002 .
2017-04-11 15:18:46 -07:00
Ben Konyi
a1f87ebdb8
Added synchronous socket implementation to dart:io.
...
BUG=
R=zra@google.com
Review-Url: https://codereview.chromium.org/2803543006 .
2017-04-11 14:41:09 -07:00
Vijay Menon
10c5de82c8
Invoke debugger on nsm
...
Missed this one when I added debugger statements earlier
R=jmesserly@google.com
Review-Url: https://codereview.chromium.org/2565183004 .
2017-04-07 14:45:09 -07:00
Vijay Menon
5c3bcff375
DDC fix for foreign futures
...
Fixes #29287
R=jmesserly@google.com
Review-Url: https://codereview.chromium.org/2804113002 .
2017-04-06 14:52:59 -07:00
Jacob Richman
509bcd58e1
Fix type checks and display for JS interop types.
...
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 .
2017-04-03 08:34:20 -07:00
Vijay Menon
08f085727e
Fix ignore on FutureOr
...
I'll look into adding tests - these eventually supposed to *not* get ignored (see #27223 )
R=leafp@google.com
Review-Url: https://codereview.chromium.org/2788933002 .
2017-03-31 09:30:16 -07:00
Zach Anderson
bc923bed16
[dart:io] Reland: Adds Platform.localeName
...
The Mac OS build broke because a typedef wasn't added until 10.12.
related #29126
Review-Url: https://codereview.chromium.org/2786183003 .
2017-03-30 13:51:46 -07:00
Zachary Anderson
e75df3cce3
Revert "[dart:io] Adds Platform.localeName"
...
This reverts commit ae6d854ec6 .
The build failed on the mac build bots. Need to investigate.
Review-Url: https://codereview.chromium.org/2791453002 .
2017-03-30 13:35:02 -07:00
Zachary Anderson
ae6d854ec6
[dart:io] Adds Platform.localeName
...
related #29126
R=fschneider@google.com
Review-Url: https://codereview.chromium.org/2785073002 .
2017-03-30 13:31:11 -07:00
Vijay Menon
84864e3415
DDC fix for Edge
...
Patch from zjd.
R=jacobr@google.com
Review-Url: https://codereview.chromium.org/2780903004 .
2017-03-29 12:22:45 -07:00
Vijay Menon
ac68d598cf
Add patch code for List.filled growable param
...
Looks like a missing param doesn't break patch_sdk. I think this was a recent add.
Fixes #28508
R=jakemac@google.com , jmesserly@google.com
Review-Url: https://codereview.chromium.org/2771953004 .
2017-03-24 14:27:47 -07:00
Leaf Petersen
dba842bcc8
Handle casts from Number to FutureOr<double>.
...
Fixes https://github.com/dart-lang/sdk/issues/29128 .
BUG=
R=vsm@google.com
Review-Url: https://codereview.chromium.org/2772573003 .
2017-03-23 13:33:33 -07:00
Vijay Menon
053d2ce14f
Fix for dcall on callable class
...
(Note, regenerated files aren't being uploaded)
Fixes #29148
R=leafp@google.com
Review-Url: https://codereview.chromium.org/2774623004 .
2017-03-23 13:14:58 -07:00
Vijay Menon
c3505f7d72
Fix async iterator runtime type errors
...
Seeing errors on the bots triggered by a recent SDK change (FutureOrT typing?). See travis for current breakage.
TBR=jmesserly@google.com
Review-Url: https://codereview.chromium.org/2769883002 .
2017-03-22 20:15:00 -07:00
Jacob Richman
66908140e7
Fix dev compiler formatter error.
...
BUG=
Review-Url: https://codereview.chromium.org/2764203002 .
2017-03-21 20:40:15 -07:00
Jennifer Messerly
f021a7019b
fixes #27586 , prefer downwards context type in generic inference
...
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 .
2017-03-17 16:59:56 -07:00
Jennifer Messerly
13d6c5cd98
fix ddc build, adds some unsupported methods to dart:io
...
R=vsm@google.com
Review-Url: https://codereview.chromium.org/2756463006 .
2017-03-17 16:23:52 -07:00
Vijay Menon
24fd5ced4f
Expand ignore whitelist to include FutureOr
...
See internal bug 36371258.
We're hitting type errors of the form:
CastError: Casting value of type '_Future' to incompatible type 'FutureOr<int>'
I suspect these type errors were there but just ignored before - does this seem a reasonable extension to the whitelist?
R=jmesserly@google.com
Review-Url: https://codereview.chromium.org/2752203003 .
2017-03-16 20:05:09 -07:00
Vijay Menon
2fd1f5ebf1
Fix FutureOr runtime check
...
Fixes #29062
This is taken straight from Jen's CL here:
https://codereview.chromium.org/2456803004/
R=jmesserly@google.com
Review-Url: https://codereview.chromium.org/2750393003 .
2017-03-16 12:54:22 -07:00
Jacob Richman
9484ac8bdf
Format all dart dev compiler files
...
BUG=
R=vsm@google.com
Review-Url: https://codereview.chromium.org/2752163002 .
2017-03-15 21:34:25 -07:00
Vijay Menon
338304a6c7
Fix DDC patch
...
TBR'ing to get build green.
TBR=rnystrom@google.com
Review-Url: https://codereview.chromium.org/2749703006 .
2017-03-15 09:23:49 -07:00
Vijay Menon
ee6f460847
Fix equality invocation on native objects
...
R=jmesserly@google.com
Review-Url: https://codereview.chromium.org/2754583002 .
2017-03-14 15:27:27 -07:00
Jacob Richman
1f38879094
Inline source maps as part of each script.
...
Unfortunately this is required as even with ideal caching, performing
XHRs to load all source maps increased load times by ~5 seconds for large
applications. Performance hit is now minimal.
BUG=
Review-Url: https://codereview.chromium.org/2747513003 .
Review-Url: https://codereview.chromium.org/2746033003 .
2017-03-13 10:46:02 -07:00
Jacob Richman
7ba7e0cee6
Make all DDC internal stack traces apply source maps.
...
Make DDC a better platform for debugging by ensuring that stack traces
generated by DDC even when using the raw dart:core StackTrace class
apply JS source maps and benefit from the polish provided by the
stack_trace package.
stack_trace_mapper.dart needs to be compiled to js and included on your
page to benefit from this functionality. Otherwise you will still see
regular JS stack traces as usual.
BUG=
R=vsm@google.com
Review-Url: https://codereview.chromium.org/2735303002 .
2017-03-08 19:13:00 -08:00
Vijay Menon
402e025c63
Add option to suppress type-check whitelisting
...
Run most tests without the whitelisting.
See #27223
R=leafp@google.com
Review-Url: https://codereview.chromium.org/2739863003 .
2017-03-08 17:51:32 -08:00
Vijay Menon
f6e964fca9
Fix dangling ddc references in libraries.dart
...
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 .
2017-03-07 15:27:46 -08:00
Jacob Richman
a6a206062d
Custom formatter cleanup Fix case where displaying a class constructor generated unreadable huge output. Fix case where exceptions were throw. Correct display of statics, fix indentation bugs. Add improved custom formatter test to main repro. As a drive by fix, switch hashCode to use a symbol instead of the name $identityHash as $identityHash was making custom formatter test output unstable.
...
BUG=
R=vsm@google.com
Review-Url: https://codereview.chromium.org/2703263002 .
2017-02-28 17:47:53 -08:00
Jennifer Messerly
fe294f3753
unfork DDC's copy of most SDK libraries
...
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 .
2017-02-28 17:10:52 -08:00
Vijay Menon
53971cb67e
Fix Function.apply
...
Fixes #27257 .
R=alanknight@google.com , jmesserly@google.com
Review-Url: https://codereview.chromium.org/2716583006 .
2017-02-24 19:24:48 -08:00
Leaf Petersen
ef120f105f
When metadata is not requested, elide signature information that is
...
not needed for dynamic checks (static fields/getters/setters and constructors).
BUG=
R=jmesserly@google.com
Review-Url: https://codereview.chromium.org/2711253004 .
2017-02-24 12:59:09 -08:00
Vijay Menon
1ec614fd7b
Enable DDC output to run on v8/d8 using ES6 modules
...
Fixes #27309
V8 / D8 tip supports ES6 modules natively. It's a little cumbersome
to set up, but hello world runs. :-)
> ln -s $DDC_PATH/lib/js/es6/ddc_sdk.js ddc_sdk
> dart $DDC_PATH/bin/dartdevc.dart --dart-sdk-summary $DDC_PATH/lib/sdk/ddc_sdk.sum --modules es6 -o hello hello.dart
> cat > run.js
import { hello } from 'hello';
hello.main();
> d8 --module run.js
R=jmesserly@google.com
Review-Url: https://codereview.chromium.org/2701963002 .
2017-02-17 16:54:21 -08:00
Leaf Petersen
fd6f2cc4cc
Add generic types to Future.forEach in DDC sdk
...
BUG=
R=vsm@google.com
Review-Url: https://codereview.chromium.org/2696133005 .
2017-02-15 11:17:25 -08:00
Ben Konyi
39f80e42e0
Corrected spelling mistake from "happend" to "happen" throughout multiple files.
...
BUG=
R=zra@google.com
Review-Url: https://codereview.chromium.org/2688943002 .
2017-02-10 12:52:42 -08:00
Vijay Menon
b27e65d5d1
Unwrap type if needed on dcall
...
R=leafp@google.com
Review-Url: https://codereview.chromium.org/2672273004 .
2017-02-06 20:51:53 -08:00
Jennifer Messerly
5817ba47e2
fix #28642 , handling of top and bottom types in DDC
...
in particular: void, Null, and combinations with FutureOr<T>
R=leafp@google.com
Review-Url: https://codereview.chromium.org/2671113002 .
2017-02-06 14:56:10 -08:00
Jacob Richman
a8c7e74424
Remove dynamic call from _LinkedHashSet. Remove some dcalls from the dart:html util library.
...
BUG=
R=alanknight@google.com , vsm@google.com
Review-Url: https://codereview.chromium.org/2666053004 .
2017-02-01 13:26:41 -08:00
Conor Reisman
80066aa2d6
Fix typo in StreamSink.close documentation ( #28572 )
...
provding -> providing.
2017-01-31 04:11:38 -08:00
Jacob Richman
f6151f902e
Fix dynamic calls on JS interop classes.
...
BUG=
Review-Url: https://codereview.chromium.org/2668543002 .
2017-01-30 14:19:07 -08:00
Jacob Richman
f3c33b047d
Remove spurious call to captureStackTrace.
...
Just creating an Error object is sufficient on FF,
Chrome, Safari, and Edge. Note that captureStackTrace
was not supported by other browsers so those browsers
were going down the even slower path of throwing an
exception.
BUG=
R=vsm@google.com
Review-Url: https://codereview.chromium.org/2668503002 .
2017-01-30 13:30:31 -08:00
Jacob Richman
959a375541
Fix getFieldType to handle metadata and workaround bad types for setters called via mirrors.
...
BUG=
R=vsm@google.com
Review-Url: https://codereview.chromium.org/2664493005 .
2017-01-27 14:23:34 -08:00
Vijay Menon
fd94337b42
Fix for Animation and other polyfills
...
The polyfill code needs to run before dart_sdk is loaded. Otherwise, the registerExtension step on these types does not work.
Also fixes #27605
R=jacobr@google.com
Review-Url: https://codereview.chromium.org/2649613003 .
2017-01-25 16:18:49 -08:00
Vijay Menon
a91cc9cc9e
Use microtasks in dart.async
...
Not quite sure about this, but it makes ordering match for the example in #28509
R=jmesserly@google.com
Review-Url: https://codereview.chromium.org/2653253002 .
2017-01-25 16:14:01 -08:00
Jennifer Messerly
0e00b3e5c8
fix #28008 , fix #28009 implement FutureOr<T>
...
This implements FutureOr<T> in strong mode, otherwise it's ignored (treated as `dynamic`.
Also fixes strong mode's inference subtype function incorrectly treating `void` as a malformed type. This had the consequence of allowing `void` to be inferred as a type argument.
R=leafp@google.com , paulberry@google.com
Review-Url: https://codereview.chromium.org/2647833002 .
2017-01-25 15:32:57 -08:00
Jacob Richman
d90ed8c295
Fix noSuchMethod handling of methods that are also extension methods. Fix noSuchMethod handling of methods with names that are rewritten in DDC e.g. "_get" instead of "[]" Fix some mirror system handling of symbols with names that are rewritten in DDC
...
BUG=
R=jmesserly@google.com
Review-Url: https://codereview.chromium.org/2623053004 .
2017-01-24 11:16:21 -08:00
Benjamin Dopplinger
bf5597c95a
Fix "classs" typos ( #28469 )
2017-01-23 17:00:24 +01:00
Vijay Menon
a7f7a311c0
Fix for covariant
...
We've been silently failing to rebuild the SDK since covariant was added.
Looking at making SDK build break fail the presubmit!
TBR=leafp@google.com ,jacobr@google.com
Review-Url: https://codereview.chromium.org/2648863002 .
2017-01-20 15:20:44 -08:00