Johnni Winther
52f1f25d34
Sort type tests.
...
- and match sorting of injected members with patched_dart2js_sdk in test
R=sigmund@google.com
Review-Url: https://codereview.chromium.org/2958553002 .
2017-06-26 12:20:03 +02:00
Johnni Winther
2e6521678a
Less inequivalence on Hello World!
...
- generate runtime types from kernel
- remove Compiler.types and add ClosedWorld.types
- start checking emitter equivalence including Program model equivalence
R=sigmund@google.com
Review-Url: https://codereview.chromium.org/2954493002 .
2017-06-26 11:30:11 +02:00
Johnni Winther
14dda16482
Handle for-loop with simple break in compile_from_dill_test
...
R=sigmund@google.com
Review-Url: https://codereview.chromium.org/2950303002 .
2017-06-26 11:10:30 +02:00
Johnni Winther
f7f4d6133b
Refactoring to prepare for kernel based jump targets
...
R=sigmund@google.com
Review-Url: https://codereview.chromium.org/2954463002 .
2017-06-26 10:35:13 +02:00
Erik Corry
029b1cb948
Spelling fixes e to i.
...
R=kevmoo@google.com
BUG=
Review-Url: https://codereview.chromium.org/2957593002 .
2017-06-24 13:41:39 +02:00
Peter von der Ahé
69d6e8e55a
All strong mode cleaning of dart2js.
...
Fixes https://github.com/dart-lang/sdk/issues/29886
Supersedes CLs 2939193003, 2950433002, and 2947583002.
R=johnniwinther@google.com
Review-Url: https://codereview.chromium.org/2944843002 .
2017-06-19 14:06:38 +02:00
Johnni Winther
208744eab7
Towards compiling Hello World!
...
R=efortuna@google.com , sigmund@google.com
Committed: https://github.com/dart-lang/sdk/commit/778feb0504759885271e166d76f0924c3bdfdb08
Reverted: https://github.com/dart-lang/sdk/commit/482502705ad05b6a14017f30b12909d97b322bdf
Review-Url: https://codereview.chromium.org/2939033002 .
2017-06-16 14:48:07 +02:00
Johnni Winther
482502705a
Revert "Towards compiling Hello World!" and "Compile and run Hello World!"
...
This reverts commit 778feb0504 and 1214e6fba6 .
Review-Url: https://codereview.chromium.org/2938193003 .
2017-06-16 11:34:05 +02:00
Johnni Winther
778feb0504
Towards compiling Hello World!
...
R=efortuna@google.com , sigmund@google.com
Review-Url: https://codereview.chromium.org/2939033002 .
2017-06-16 10:45:23 +02:00
Peter von der Ahé
b4066914eb
Late night strong mode cleaning.
...
R=efortuna@google.com
Review-Url: https://codereview.chromium.org/2942763002 .
2017-06-15 09:44:50 +02:00
Peter von der Ahé
06b8ce5d34
More dart2js strong mode cleanup.
...
R=efortuna@google.com
Review-Url: https://codereview.chromium.org/2934333002 .
2017-06-15 09:42:22 +02:00
Johnni Winther
6a6a330623
Parameterize and move JumpTarget/LabelDefition to elements/jumps.dart
...
R=efortuna@google.com
Review-Url: https://codereview.chromium.org/2930293002 .
2017-06-14 12:27:38 +02:00
Johnni Winther
7bd8cfe670
Handle instance fields in compile_from_dill_test
...
R=efortuna@google.com
Review-Url: https://codereview.chromium.org/2929143002 .
2017-06-12 09:46:37 +02:00
Johnni Winther
b1f129d258
Add MemberEntity.member and refactor Emitter.getReflectionName to avoid mixin Selector and Entity
...
R=efortuna@google.com
Review-Url: https://codereview.chromium.org/2933553002 .
2017-06-12 09:42:22 +02:00
Johnni Winther
0f7ee4a6ed
A step towards handling new Object() in compile_from_dill_test
...
R=sigmund@google.com
Review-Url: https://codereview.chromium.org/2925263002 .
2017-06-09 11:58:30 +02:00
Stephen Adams
49e2cfc295
Use failedAt in more places
...
R=johnniwinther@google.com
BUG=
Review-Url: https://codereview.chromium.org/2917653002 .
2017-06-03 02:48:16 -07:00
Johnni Winther
8acac25e5e
Handle list and map literals
...
R=sigmund@google.com
Review-Url: https://codereview.chromium.org/2918913003 .
2017-06-02 20:53:15 +02:00
Johnni Winther
9c782896e9
Handle static invocation
...
+ implement Sorter for kernel entities.
R=sigmund@google.com
Review-Url: https://codereview.chromium.org/2918543003 .
2017-06-01 10:00:43 +02:00
Stephen Adams
d5f2138349
Use failedAt in more places
...
BUG=
R=johnniwinther@google.com
Review-Url: https://codereview.chromium.org/2898403002 .
2017-05-31 03:12:11 -07:00
Johnni Winther
0d0905cd81
It's alive!
...
With this change the empty program compiles and runs from .dill
R=sigmund@google.com
Review-Url: https://codereview.chromium.org/2908153003 .
2017-05-31 10:24:48 +02:00
Lasse R.H. Nielsen
5cbb22faf2
Make dart2js understand relative part-of in platform libraries.
...
R=johnniwinther@google.com
Review-Url: https://codereview.chromium.org/2909043002 .
2017-05-29 15:12:43 +02:00
Johnni Winther
43efd5039b
Add FunctionEntity.asyncMarker and refactor SourceInformationStrategy to avoid ResolvedAst
...
With this change the empty program now runs until codegen onQueueEmpty.
R=sigmund@google.com
Review-Url: https://codereview.chromium.org/2897273002 .
2017-05-29 10:37:23 +02:00
Sigmund Cherem
dd70d8b655
Remove factory body in *.fromEnvironment, and implement this same behavior
...
directly inside dart2js.
A few notes:
* I ended up adding support for this feature also in dart2js with --use-kernel, it was not implemented correctly before. This is why more tests are passing.
* I played with two other ideas:
(a) making this a compile-time error instead
(b) making it a warning if the arguments were constant and implement it as a constant, treat it as an error if they were not.
Unfortunately both are a breaking changes, so I backed out from them. IMO (a) is the cleanest thing to do long term, and we should raise this with the language team.
R=efortuna@google.com
Review-Url: https://codereview.chromium.org/2896393003 .
2017-05-26 14:49:19 -07:00
Johnni Winther
ac07b3ce03
Type .targetElement as MemberEntity
...
+ decouple LocalsHandler from ExecutableElement
R=efortuna@google.com
Review-Url: https://codereview.chromium.org/2901823002 .
2017-05-24 10:23:33 +02:00
Stephen Adams
e7e7d0c1b4
Use failedAt in more places (misc2)
...
TBR=sigmnd@google.com
Review-Url: https://codereview.chromium.org/2905573002 .
2017-05-23 19:04:16 -07:00
Stephen Adams
d2688c4ce6
Redo "dart2js: replace 'invariant' with 'failedAt' to defer interpolation"
...
TBR=johnniwinther@google.com
BUG=
Review-Url: https://codereview.chromium.org/2904613002 .
2017-05-23 11:44:52 -07:00
Stephen Adams
3e72e09a97
Revert "dart2js: replace 'invariant' with 'failedAt' to defer interpolation"
...
Investigating some analyzer warnings.
TBR=johnniwinther@google.com
BUG=
Review-Url: https://codereview.chromium.org/2897093002 .
2017-05-23 10:48:41 -07:00
Stephen Adams
641767c1da
dart2js: replace 'invariant' with 'failedAt' to defer interpolation
...
Speeds up dart2js_builds by ~5% (probably more with more replacements).
BUG=
R=johnniwinther@google.com
Review-Url: https://codereview.chromium.org/2902633002 .
2017-05-23 08:25:52 -07:00
Johnni Winther
789fce309f
Add ElementCodegenWorldBuilder
...
Reusable parts are left in CodegenWorldBuilderImpl and a stub KernelCodegenWorldBuilder is added.
R=sigmund@google.com
Review-Url: https://codereview.chromium.org/2894893002 .
2017-05-22 10:05:57 +02:00
Johnni Winther
b30ff8ed66
Use entities in runtime_types
...
- and make it its own library.
R=sigmund@google.com
Review-Url: https://codereview.chromium.org/2884233002 .
2017-05-18 10:09:40 +02:00
Johnni Winther
dff23682a1
Create closed world for hello world using .dill file
...
Currently results in compile time error because of a bug in the kernel reuse of mixin applications.
R=sigmund@google.com
Review-Url: https://codereview.chromium.org/2865693002 .
2017-05-16 10:30:05 +02:00
Johnni Winther
ab688ab590
Make elements/names.dart its own library
...
R=sigmund@google.com
Review-Url: https://codereview.chromium.org/2860753005 .
2017-05-08 11:00:32 +02:00
Johnni Winther
0adb70eb52
Move resolution/operators.dart to elements/operators.dart
...
R=sigmund@google.com
Review-Url: https://codereview.chromium.org/2862163003 .
2017-05-08 10:08:32 +02:00
Johnni Winther
e4131c2d37
Reuse RuntimeTypesNeedBuilderImpl and _RuntimeTypesNeed for kernel based elements
...
R=sigmund@google.com
Review-Url: https://codereview.chromium.org/2850143002 .
2017-05-03 09:54:21 +02:00
Johnni Winther
82d47e6b91
Fix InterfaceType.treatAsRaw
...
R=sigmund@google.com
Review-Url: https://codereview.chromium.org/2852683002 .
2017-05-01 09:19:59 +02:00
Johnni Winther
ba82b69567
Change toString on ResolutionTypeVariableType to include class/method name
...
R=sigmund@google.com
Review-Url: https://codereview.chromium.org/2846903002 .
2017-04-28 09:58:37 +02:00
Johnni Winther
600ecf5e72
Use more entities in program_builder, collector and registry
...
This a step towards decoupling the emitter from the choice of codegen element model.
R=sigmund@google.com
Review-Url: https://codereview.chromium.org/2843283004 .
2017-04-28 09:53:45 +02:00
Johnni Winther
0390e9f0af
Implement subtype relation for kernel based elements.
...
+ check BackendUsage equivalence
R=sigmund@google.com
Review-Url: https://codereview.chromium.org/2827283002 .
2017-04-24 10:53:05 +02:00
Johnni Winther
8a9c0417af
Extract DartTypeVisitor and subclasses from resolution_types.
...
This makes most of the subtype related visitors reusable by kernel based elements.
R=sigmund@google.com
Review-Url: https://codereview.chromium.org/2829683007 .
2017-04-24 09:01:22 +02:00
Johnni Winther
5ccf530f62
Extract OrderedTypeSetBuilderBase from OrderedTypeSetBuilder
...
- to make it reusable for kernel based elements.
R=efortuna@google.com
Review-Url: https://codereview.chromium.org/2808763005 .
2017-04-18 09:29:39 +02:00
Emily Fortuna
93a908fde0
Remove BackendClasses and JavaScriptBackendClasses.
...
BUG=
R=johnniwinther@google.com , sra@google.com
Review-Url: https://codereview.chromium.org/2813093002 .
2017-04-13 17:22:54 -07:00
Johnni Winther
ad52db16e0
Add kernel/closed_world2_test
...
This is a step towared computing the closed world purely from kernel based elements.
The added test runs the resolution enqueuer on a kernel based world.
Some methods and classes are mocked and no closed world object is computed, yet.
R=efortuna@google.com
Review-Url: https://codereview.chromium.org/2810633003 .
2017-04-11 10:33:46 +02:00
Johnni Winther
e5bb7df19b
Use entities in Selector methods
...
This makes these methods reusable for kernel based elements.
R=efortuna@google.com
Review-Url: https://codereview.chromium.org/2810683002 .
2017-04-11 10:22:55 +02:00
Johnni Winther
21a3455bd6
Introduce ParameterStructure
...
This is a substructure of FunctionType and FunctionSignature which
doesn't contain type information. This allows us to let FunctionEntity
have a ParameterStructure (which makes sense for both K and J elements)
but not require FunctionEntity to have a type (which K elements have
but J elements might not).
R=efortuna@google.com
Review-Url: https://codereview.chromium.org/2809603002 .
2017-04-11 10:19:14 +02:00
Johnni Winther
77bd26f3d7
Add MemberEntity.isAbstract and use MemberEntity in function_set.dart
...
This makes function_set.dart reusable for kernel based elements.
R=efortuna@google.com
Review-Url: https://codereview.chromium.org/2804293002 .
2017-04-11 10:10:04 +02:00
Johnni Winther
b4ef45d6e4
Use entities in impact transformers.
...
This makes the impact transformers reusable for kernel based elements.
R=efortuna@google.com
Review-Url: https://codereview.chromium.org/2807593002 .
2017-04-11 10:02:53 +02:00
Johnni Winther
97b19651a5
Extract ResolutionWorldBuilderBase from ElementResolutionWorldBuilder
...
This is a step towards reusing parts of ElementResolutionWorldBuilder
for kernel-based elements.
R=efortuna@google.com
Review-Url: https://codereview.chromium.org/2804993002 .
2017-04-07 09:59:49 +02:00
Johnni Winther
7108d7b7a4
Remove use of Element in ResolutionEnqueuerListener.
...
This makes ResolutionEnqueuerListener reusable for kernel-based elements.
R=efortuna@google.com
Review-Url: https://codereview.chromium.org/2797173004 .
2017-04-07 09:41:57 +02:00
Peter von der Ahé
5bdc1199ca
Fix dart2js warnings and add test to ensure it stays clean.
...
Filed https://github.com/dart-lang/sdk/issues/29224 to track all the problems that require ignore.
R=johnniwinther@google.com
Review-Url: https://codereview.chromium.org/2791993002 .
2017-04-03 15:08:40 +02:00
Peter von der Ahé
323d5b0b7f
Track async state in parser.
...
R=johnniwinther@google.com
Review-Url: https://codereview.chromium.org/2759623003 .
2017-03-17 14:43:07 +01:00