Emily Fortuna
9b003dd2f9
Make try/catch/finally work with Kernel code and some refactoring.
...
BUG=https://github.com/dart-lang/sdk/issues/27394
R=sigmund@google.com
Review-Url: https://codereview.chromium.org/2570273004 .
2016-12-15 09:08:16 -08:00
Harry Terkelsen
c05c73f077
add --assert-message flag back
...
Review-Url: https://codereview.chromium.org/2579523003 .
2016-12-14 17:24:55 -08:00
Harry Terkelsen
4b840f2d13
fix assert with message
...
Fixes https://github.com/dart-lang/sdk/issues/28106
R=sigmund@google.com
Review-Url: https://codereview.chromium.org/2576113002 .
2016-12-14 15:51:49 -08:00
Florian Loitsch
7374ec71bd
Remove support for mixin typedefs in dart2js.
...
Fixes #14410 .
BUG= http://dartbug.com/14410
R=johnniwinther@google.com , sigmund@google.com
Review-Url: https://codereview.chromium.org/2567943003 .
2016-12-13 14:04:06 +01:00
Johnni Winther
a2483321a3
Even less reliance on Compiler.closedWorld
...
R=sigmund@google.com
Review-Url: https://codereview.chromium.org/2569733002 .
2016-12-13 10:38:04 +01:00
Johnni Winther
d4c9dc92e1
Fix rti encoding of generic methods
...
R=sigmund@google.com
Review-Url: https://codereview.chromium.org/2565413002 .
2016-12-13 10:27:59 +01:00
Florian Loitsch
cc2eba8c2a
Implement FutureOr<T> for dart2js.
...
In dart2js, FutureOr<T> should simply be treated as `dynamic`.
Fixes #28011
BUG= http://dartbug.com/28011
R=johnniwinther@google.com , sigmund@google.com
Review URL: https://codereview.chromium.org/2559523006 .
2016-12-12 15:21:03 +01:00
Johnni Winther
e00732643f
Remove CodegenEnqueuer.compiler
...
R=het@google.com
Review-Url: https://codereview.chromium.org/2564823002 .
2016-12-12 10:59:48 +01:00
Johnni Winther
7953afaee6
Remove Compiler.inferenceWorld
...
R=sigmund@google.com
Review-Url: https://codereview.chromium.org/2559373004 .
2016-12-12 10:48:18 +01:00
Johnni Winther
415ba7948c
Reduce use of Compiler.closedWorld
...
- in preparation for passing ClosedWorld directly between phases.
R=sigmund@google.com
Review-Url: https://codereview.chromium.org/2563443007 .
2016-12-12 10:35:23 +01:00
Stephen Adams
1dba7a80a5
Add associations for more null-aware cases
...
BUG=
R=efortuna@google.com
Review-Url: https://codereview.chromium.org/2562703008 .
2016-12-09 12:26:44 -08:00
Johnni Winther
925160e2d0
dartfmt dart2js and unittests
...
Using dartfmt version 0.2.13
R=sra@google.com
Review URL: https://codereview.chromium.org/2557313002 .
2016-12-09 10:59:50 +01:00
Johnni Winther
a9a96d73fe
Merge _applyMemberUse and _applyStaticMemberUse in ResolutionEnqueuer
...
R=het@google.com
Review URL: https://codereview.chromium.org/2563623002 .
2016-12-09 10:50:49 +01:00
Stephen Adams
1eed1ae5e2
dart2js-kernel: ir.EmptyStatement
...
TBR=efortuna@google.com
Review-Url: https://codereview.chromium.org/2563633003 .
2016-12-08 19:25:51 -08:00
Stephen Adams
d08720c1e4
dart2js-kernel: Handle ir.TypeLiteral for type variables
...
R=efortuna@google.com
Review-Url: https://codereview.chromium.org/2566563002 .
2016-12-08 16:30:57 -08:00
Stephen Adams
71a344438d
dart2js-kernel: associate more compound assignment inner nodes
...
We can now find the inner nodes (reads and binary operations) of
a[i]++, ++a[i], a[i]*=9.
R=efortuna@google.com
Review-Url: https://codereview.chromium.org/2561843002 .
2016-12-08 11:46:48 -08:00
Johnni Winther
fa038d003b
Remove Compiler.openWorld
...
R=sigmund@google.com
Review URL: https://codereview.chromium.org/2556073002 .
2016-12-08 10:20:17 +01:00
Johnni Winther
80bd26db9b
Remove ResolutionEnqueuer._applyFirstMemberUse
...
R=het@google.com
Review URL: https://codereview.chromium.org/2554323002 .
2016-12-08 10:14:49 +01:00
Johnni Winther
709a355284
Move hasRuntimeTypeSupport, hasIsolateSupport, and hasFunctionApplySupport to JavaScriptBackend.
...
R=het@google.com
Review URL: https://codereview.chromium.org/2558763003 .
2016-12-08 10:08:24 +01:00
Johnni Winther
015ff75143
Move handling of regular static use from ResolutionEnqueuer to ResolutionWorldBuilderImpl
...
R=het@google.com
Review URL: https://codereview.chromium.org/2558013002 .
2016-12-08 10:01:16 +01:00
Johnni Winther
53eb4028d8
Change Enqueuer to use Entity instead of Element.
...
R=het@google.com
Review URL: https://codereview.chromium.org/2549423002 .
2016-12-08 09:51:17 +01:00
Stephen Adams
d7b2670e58
Generate traps for unhandled statement nodes
...
TBR=efortuna@google.com
Review URL: https://codereview.chromium.org/2561743002 .
2016-12-07 20:09:19 -08:00
Stephen Adams
a9b8d6ce2a
Some resolution runtime errors are kernel malformedTypeErrors
...
We need to make sure both methods are available since we don't know which resolution errors will use which helper.
R=efortuna@google.com
Review URL: https://codereview.chromium.org/2562583003 .
2016-12-07 19:26:37 -08:00
Stephen Adams
c4a39f4d51
Generate throw statements at statement level
...
Also enable -DDUMP_IR tracing for --use-kernel
BUG=
R=sigmund@google.com
Review URL: https://codereview.chromium.org/2548363011 .
2016-12-07 16:43:06 -08:00
Stephen Adams
e2f4479caa
Fix unresolved identifier impact to include symbols
...
BUG=
R=efortuna@google.com
Review URL: https://codereview.chromium.org/2553333002 .
2016-12-07 11:18:57 -08:00
Emily Fortuna
2529184b9d
Handle top level fields with Kernel.
...
BUG=https://github.com/dart-lang/sdk/issues/27394
R=sigmund@google.com
Review URL: https://codereview.chromium.org/2537553002 .
2016-12-07 10:08:53 -08:00
Emily Fortuna
0631ed9187
Now also support FunctionDeclarations instead of just closures.
...
BUG=https://github.com/dart-lang/sdk/issues/27394
R=sra@google.com
Review URL: https://codereview.chromium.org/2558633002 .
2016-12-06 17:32:10 -08:00
Emily Fortuna
dad37d0386
Handle closures, aka FunctionExpression in Kernel!
...
BUG=https://github.com/dart-lang/sdk/issues/27394
R=het@google.com , sra@google.com
Review URL: https://codereview.chromium.org/2549233004 .
2016-12-06 11:16:31 -08:00
Stephen Adams
9f373eb5be
Insert default arguments for static calls and constructor calls.
...
https://github.com/dart-lang/sdk/issues/27394
R=efortuna@google.com , johnniwinther@google.com , sigmund@google.com
Review URL: https://codereview.chromium.org/2550323002 .
2016-12-06 11:14:59 -08:00
Florian Loitsch
80da37ed25
Fix csp mode on platforms that don't support __proto__.
...
Fixes #27290
BUG= http://dartbug.com/27290
R=sigmund@google.com
Review URL: https://codereview.chromium.org/2550903002 .
2016-12-06 14:31:52 +01:00
Johnni Winther
61d10296ee
Move processing of instantiated classes from ResolutionEnqueuer to ResolutionWorldBuilderImpl
...
R=het@google.com
Review URL: https://codereview.chromium.org/2545413002 .
2016-12-06 10:54:13 +01:00
Johnni Winther
662feb94d7
Move processing of instance members from ResolutionEnqueuer to ResolutionWorldBuilderImpl
...
R=het@google.com
Review URL: https://codereview.chromium.org/2543753004 .
2016-12-06 10:32:33 +01:00
Stephen Adams
cde06d411d
dart2js-kernel: Fix code for JS_SET_STATIC_STATE
...
BUG=
R=efortuna@google.com , sigmund@google.com
Review URL: https://codereview.chromium.org/2538233005 .
2016-12-05 12:28:48 -08:00
Stephen Adams
7207dcd376
dart2js-kernel: Implement JS_CALL_IN_ISOLATE
...
R=sigmund@google.com
Review URL: https://codereview.chromium.org/2551713002 .
2016-12-05 11:03:00 -08:00
Stephen Adams
3e7aaeebe4
Handle synthetic nodes use to throw exceptions
...
- Implement:
- - _genericNoSuchMethod
- - _unresolvedConstructorError
- - _malformedTypeError
- Temporarily change NoSuchMethod.toString to avoid a closure.
- Temporarily provide argument to StringBuffer to work around bug.
BUG=
R=sigmund@google.com
Review URL: https://codereview.chromium.org/2545153002 .
2016-12-02 16:11:26 -08:00
Stephen Adams
f62009a3aa
dart2js-kernel: Handle some more 'is' cases
...
Adds type variables and function types.
Still missing parameterized interface types.
R=sigmund@google.com
Review URL: https://codereview.chromium.org/2542783002 .
2016-12-01 09:28:02 -08:00
Johnni Winther
27afcc4296
Remove EnqueuerImpl.processInstantiatedClassMembers
...
R=het@google.com
Review URL: https://codereview.chromium.org/2539043002 .
2016-12-01 11:10:36 +01:00
Johnni Winther
489199eff1
Disallow null in spanFromSpannable.
...
Closes #27938
R=sigmund@google.com
Review URL: https://codereview.chromium.org/2537303004 .
2016-12-01 10:53:56 +01:00
Stephen Adams
ece7725d90
dart2js-kernel: Emit error trap for unimplemented features
...
The test will fail with an error like the following, rather than proceed with an incorrect null value.
R=efortuna@google.com
Review URL: https://codereview.chromium.org/2540363002 .
TypeError: Cannot read property 'Unhandled ir.FunctionExpression (dynamic x) → dynamic => x' of null
2016-11-30 16:52:07 -08:00
Stephen Adams
dfd38a0463
Use precomputed constant for determining if static is lazy-init
...
R=sigmund@google.com
Review URL: https://codereview.chromium.org/2541753002 .
2016-11-30 13:31:56 -08:00
Johnni Winther
33303ffea5
Resolve type arguments to generic methods.
...
R=eernst@google.com
Review URL: https://codereview.chromium.org/2535373003 .
2016-11-30 12:44:29 +01:00
Johnni Winther
40bf5d321e
Handle 'dynamic' as type argument in generic calls.
...
R=eernst@google.com
Review URL: https://codereview.chromium.org/2541473002 .
2016-11-30 09:29:35 +01:00
Johnni Winther
44bdc75827
Support patched generic methods.
...
R=sigmund@google.com
Review URL: https://codereview.chromium.org/2535213003 .
2016-11-30 09:20:42 +01:00
Johnni Winther
3af747810f
More refactoring of enqueuers
...
- refactor enqueuer/strategy/impact-visitor relations
- make helper methods/fields private
R=het@google.com
Review URL: https://codereview.chromium.org/2535143003 .
2016-11-30 09:12:08 +01:00
Stephen Adams
9871523b61
Recognise x.==(null) and generate HIdentical
...
This handles many of the kernel null-aware expansions, which do not map back to Ast nodes.
R=efortuna@google.com , sigmund@google.com
Review URL: https://codereview.chromium.org/2535323002 .
2016-11-29 15:05:52 -08:00
Emily Fortuna
ecb9b3618a
Handle "as" in kernel with ir.AsExpression case.
...
BUG=https://github.com/dart-lang/sdk/issues/27394
R=sra@google.com
Review URL: https://codereview.chromium.org/2538643002 .
2016-11-29 12:46:43 -08:00
Stephen Adams
84aa1746e2
dart2js-kernel: Implement RAW_DART_FUNCTION_REF
...
BUG=
R=sigmund@google.com
Review URL: https://codereview.chromium.org/2540603002 .
2016-11-29 10:16:37 -08:00
Johnni Winther
258ed14ae3
Decouple WorkItem from Compiler
...
- Remove Compiler and Enqueuer arguments from WorkItem.run
- Move show progress from WorkItem.run to Compiler.showXProgress methods
- Move Compiler.analyzeElement to Resolution.computeWorldImpact
- Move Compiler.analyze to ResolutionWorkItem Move Compiler.codegen to CodegenWorkItem
R=het@google.com
Review URL: https://codereview.chromium.org/2531303002 .
2016-11-29 09:31:41 +01:00
Johnni Winther
fbc69f1e9e
Merge QueueFilter with EnqueuerStrategy
...
R=het@google.com
Review URL: https://codereview.chromium.org/2529273003 .
2016-11-29 09:22:13 +01:00
Johnni Winther
417d4d7a50
Further encapsulate Enqueuer
...
R=het@google.com
Review URL: https://codereview.chromium.org/2527403002 .
2016-11-29 09:14:09 +01:00