asiva@google.com
c00b3d5571
The Dart VM also supports delayed parsing of classses now. As a part
...
of this change some negative tests which assumed eager loading of classes
were fixed.
The dart2dart part in language.status file has been updated to account for this.
Review URL: https://codereview.chromium.org//16023010
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@23183 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-24 21:16:08 +00:00
asiva@google.com
f48cd7fc04
The Dart VM also supports delayed parsing of classses now. As a part
...
of this change some negative tests which assumed eager loading of classes
were fixed.
The language_dart2js.status file has been updated to account for this.
Review URL: https://codereview.chromium.org//16020010
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@23180 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-24 21:00:32 +00:00
asiva@google.com
c9fc32dda7
Fix for issue 10839, use the class in order to trigger compilation.
...
R=hausner@google.com
Review URL: https://codereview.chromium.org//15735023
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@23175 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-24 20:09:29 +00:00
asiva@google.com
7b986d83dc
Fix dartium build break.
...
Review URL: https://codereview.chromium.org//15800003
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@23118 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-24 00:45:16 +00:00
asiva@google.com
a1da7e93a4
Fix some of the negative language tests in preparation for implementing
...
delayed class parsing in Dart VM.
- Some of the tests under tests/language expect compile-time errors but
these tests do not use the class which has errors. When the VM will
implement delayed parsing of classes (classes are parsed only if they
are used) these tests will fail as the Dart VM will not report these as
compile-time errors. The option VMOptions=--compile_all has been added
to these tests to ensure that all classes are compiled and the error
is reported.
- One co19 test has a similar issue and a bug has been filed against it
(co19 issue 415). the co19-runtime.status file has been updated to
skip this test until issue 415 is resolved.
R=iposva@google.com
Review URL: https://codereview.chromium.org//15496005
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@23113 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-23 23:38:56 +00:00
scheglov@google.com
0441460914
Issue 8365. Report error when user library imports an internal SDK library.
...
https://code.google.com/p/dart/issues/detail?id=8365
R=brianwilkerson@google.com , jwren@google.com
BUG=
Review URL: https://codereview.chromium.org//15741017
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@23104 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-23 20:59:09 +00:00
scheglov@google.com
9c459f8ae0
Issue 8801. Report problems for missing [] or []=
...
https://code.google.com/p/dart/issues/detail?id=8801
R=brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org//15813002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@23078 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-23 16:31:10 +00:00
ngeoffray@google.com
61622d057b
Make sure the type arguments of the supertype of a class are being added to the isCheck set. That supertype may not be instantiated.
...
R=karlklose@google.com
Review URL: https://codereview.chromium.org//15854002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@23058 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-23 10:49:35 +00:00
scheglov@google.com
8f26879fe9
Report parameters/arguments count mismatch
...
https://code.google.com/p/dart/issues/detail?id=10108
https://code.google.com/p/dart/issues/detail?id=10302
https://code.google.com/p/dart/issues/detail?id=10494
R=brianwilkerson@google.com , jwren@google.com
BUG=
Review URL: https://codereview.chromium.org//15745013
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@23039 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-22 19:36:50 +00:00
karlklose@google.com
1ed6793f0b
Use assertSubtype for lists.
...
Also omit access to as-fields if possible.
R=johnniwinther@google.com
Review URL: https://codereview.chromium.org//15735003
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@23014 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-22 13:10:25 +00:00
ngeoffray@google.com
ce27cf3491
Remove this test. It is covered by tests/language/factory_return_type_checked_test.dart.
...
R=karlklose@google.com
Review URL: https://codereview.chromium.org//15714002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@23002 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-22 09:53:50 +00:00
ngeoffray@google.com
78fcea3753
Specialize the return type of a factory constructor to be the enclosing type.
...
R=karlklose@google.com
Review URL: https://codereview.chromium.org//15712002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22999 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-22 09:17:49 +00:00
ngeoffray@google.com
a4bd18ee48
Do the null deref guard before doing inlining, especially before doing type checks on the parameters.
...
R=kasperl@google.com
Review URL: https://codereview.chromium.org//15689002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22985 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-22 07:36:11 +00:00
scheglov@google.com
9782f5dd95
Fix status files and test.
...
Forgot to rollback one test.
R=brianwilkerson@google.com , jwren@google.com
BUG=
Review URL: https://codereview.chromium.org//15563012
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22947 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-21 16:15:35 +00:00
scheglov@google.com
9bb9bd3c36
Report DUPLICATE_CONSTRUCTOR_NAME and other scope fixes
...
R=brianwilkerson@google.com , jwren@google.com
BUG=
Review URL: https://codereview.chromium.org//15271006
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22945 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-21 15:35:43 +00:00
ngeoffray@google.com
19be1133e1
When recording the type of a captured variable/parameter, use the closure field it maps to. Otherwise, there is a confusion for a parameter between the type given by its callers, and the actual type in the method, where the parameter can be updated explictly, or implicitly by the inferrer on "is checks".
...
R=karlklose@google.com
Review URL: https://codereview.chromium.org//15414004
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22939 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-21 14:09:11 +00:00
ngeoffray@google.com
28c458b0f2
Add the cast equivalent of assertSubtype and assertSubtypeOfRuntimeType.
...
R=karlklose@google.com
Review URL: https://codereview.chromium.org//15563003
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22938 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-21 13:22:16 +00:00
ngeoffray@google.com
61c33391e5
Fix a pretty bad bug of a class inheriting a patched class. The fix is
...
1) only use declarations when quering for subtypes or subclasses
2) allow to lookup injected members and super injected members in lookupSelector and forEachMember.
R=johnniwinther@google.com
Review URL: https://codereview.chromium.org//15381002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22930 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-21 11:06:46 +00:00
ngeoffray@google.com
426908c634
Detect dead code, and handle breaks and continues in inferrer.
...
R=johnniwinther@google.com
Review URL: https://codereview.chromium.org//14623030
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22929 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-21 10:47:20 +00:00
scheglov@google.com
1242ab6487
Report MULTIPLE_REDIRECTING_CONSTRUCTOR_INVOCATIONS and other redirection related.
...
R=brianwilkerson@google.com , jwren@google.com
BUG=
Review URL: https://codereview.chromium.org//15316011
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22899 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-20 19:49:44 +00:00
scheglov@google.com
e79e1c52c7
Report CTEC.IMPLICIT_THIS_REFERENCE_IN_INITIALIZER
...
R=brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org//15409002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22888 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-19 23:47:10 +00:00
scheglov@google.com
a7c769e55c
Fix dartc bot.
...
TBR
R=brianwilkerson@google.com , jwren@google.com
BUG=
Review URL: https://codereview.chromium.org//15400002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22884 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-18 01:40:17 +00:00
scheglov@google.com
f072f62f11
Handle the new analyzer type warnings in tests.
...
Unfortunately we are back to 600+ failing tests.
R=brianwilkerson@google.com , jwren@google.com
BUG=
Review URL: https://codereview.chromium.org//14858051
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22876 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-17 21:55:52 +00:00
scheglov@google.com
14cebd0b05
Report ParserErrorCode.MISSING_IDENTIFIER
...
Fixes many trivial co19 tests.
R=brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org//15260002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22875 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-17 21:37:14 +00:00
scheglov@google.com
f9b3d290cd
Report UNDEFINED_CONSTRUCTOR_IN_INITIALIZER and others
...
R=brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org//14856021
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22855 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-17 16:09:04 +00:00
scheglov@google.com
c1e870fc03
Report CTEC.RECURSIVE_CONSTRUCTOR_REDIRECT
...
R=brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org//15162010
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22852 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-17 15:35:33 +00:00
ngeoffray@google.com
1550ee6fa2
Handle switch statement in simple types inferrer.
...
BUG=10581
R=johnniwinther@google.com
Review URL: https://codereview.chromium.org//14890026
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22850 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-17 14:46:31 +00:00
karlklose@google.com
35da54ead7
Reapply "Enable full type-checks in checked mode."
...
R=ngeoffray@google.com
Review URL: https://codereview.chromium.org//15299002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22846 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-17 11:46:39 +00:00
karlklose@google.com
7be3121cb7
Revert "Reapply "Enable full type-checks in checked mode.""
...
This reverts commit r22840.
Review URL: https://codereview.chromium.org//15287002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22843 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-17 10:24:30 +00:00
karlklose@google.com
c4c7c4ba98
Reapply "Enable full type-checks in checked mode."
...
This reapplies codereview.chromium.org/13019003/ with a bug fix for type-variable references in factory constructors.
R=ngeoffray@google.com
Review URL: https://codereview.chromium.org//15023021
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22840 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-17 09:53:19 +00:00
johnniwinther@google.com
cb7bedf860
Implement continue for switch.
...
The overall strategy is to convert the following:
switch (e) {
l_0: case e0: s_0; break;
l_1: case e1: s_1; continue l_i;
...
l_n: default: s_n; continue l_j;
}
into this:
var label;
switch (e) {
case e0: label = 0; break;
case e1: label = 1; break;
...
default: label = n; break;
}
l: while (true) {
switch (label) {
case 0: s_0; break l;
case 1: s_1; label = i; continue l;
...
case n: s_n; label = j; continue l;
}
}
BUG=http://dartbug.com/8270
R=ngeoffray@google.com
Review URL: https://codereview.chromium.org//14969004
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22838 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-17 09:35:05 +00:00
scheglov@google.com
f7f4a68d72
Report ParserErrorCode.CONSTRUCTOR_WITH_RETURN_TYPE
...
R=brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org//15063006
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22824 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-16 23:13:29 +00:00
scheglov@google.com
e2d48ce25a
Report CTEC.FIELD_INITIALIZER_REDIRECTING_CONSTRUCTOR
...
R=brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org//14951006
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22821 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-16 22:46:29 +00:00
scheglov@google.com
0523ecb9db
Report CompileTimeErrorCode.REFERENCE_TO_DECLARED_VARIABLE_IN_INITIALIZER
...
R=brianwilkerson@google.com , jwren@google.com
BUG=
Review URL: https://codereview.chromium.org//14569025
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22795 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-16 15:02:50 +00:00
ngeoffray@google.com
8190de1143
Handle super calls in the backend type inferrer.
...
R=karlklose@google.com
Review URL: https://codereview.chromium.org//15222002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22782 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-16 11:12:34 +00:00
ngeoffray@google.com
466504f4f0
Fix bug in checked mode: we need to register super fields as well, because the super class might not be instantiated.
...
R=karlklose@google.com
Review URL: https://codereview.chromium.org//15023019
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22773 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-16 07:52:13 +00:00
scheglov@google.com
ed18ddd4d5
Report CompileTimeErrorCode.RECURSIVE_FACTORY_REDIRECT
...
R=brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org//14668014
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22759 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-15 22:19:23 +00:00
scheglov@google.com
b1ac8785fa
Report NON_CONSTANT_VALUE_IN_INITIALIZER
...
R=brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org//15096008
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22747 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-15 16:59:17 +00:00
scheglov@google.com
4a64347799
Report CompileTimeErrorCode.INVALID_CONST_FACTORY
...
R=brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org//14654013
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22746 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-15 16:24:00 +00:00
ahe@google.com
86cfce956e
Fix a type error in Primitives.applyFunction.
...
R=karlklose@google.com
Review URL: https://codereview.chromium.org//14969038
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22743 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-15 15:19:07 +00:00
karlklose@google.com
a80f7eb610
Revert "Enable full type-checks in checked mode."
...
This reverts commit r22735.
BUG=
Review URL: https://codereview.chromium.org//14698026
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22740 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-15 14:18:56 +00:00
karlklose@google.com
e78c52f366
Enable full type-checks in checked mode.
...
BUG=
R=ngeoffray@google.com
Review URL: https://codereview.chromium.org//13019003
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22735 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-15 13:40:59 +00:00
ngeoffray@google.com
92385b8949
Now that we inline instance methods on all kinds of receivers (not only "this" calls), we need to do an explicit null check.
...
R=karlklose@google.com
Review URL: https://codereview.chromium.org//14772041
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22734 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-15 13:16:26 +00:00
ngeoffray@google.com
e5000c01c4
Fix performance regression after adding inlining support for operators, [], and []=.
...
R=karlklose@google.com
Review URL: https://codereview.chromium.org//14783015
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22731 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-15 11:38:23 +00:00
ahe@google.com
bd9ac5d295
Update status files for dart2js mirror tests
...
Review URL: https://codereview.chromium.org//14631027
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22724 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-15 08:48:22 +00:00
scheglov@google.com
76e2c6438d
Report CompileTimeErrorCode.INVALID_FACTORY_NAME_NOT_A_CLASS
...
R=brianwilkerson@google.com , jwren@google.com
BUG=
Review URL: https://codereview.chromium.org//14671018
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22706 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-14 21:39:51 +00:00
iposva@google.com
2aeb172512
- Correctly handle negative constant indices when
...
constant propagation has not eliminated range checks.
- Add test to verify the optimizer does not
allow negative constant indices when eliminating
array bounds checks.
R=srdjan@google.com
Review URL: https://codereview.chromium.org//14566020
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22705 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-14 20:33:04 +00:00
scheglov@google.com
88943dfad4
Report CompileTimeErrorCode.SUPER_IN_INVALID_CONTEXT
...
R=brianwilkerson@google.com , jwren@google.com
BUG=
Review URL: https://codereview.chromium.org//14622019
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22694 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-14 18:13:54 +00:00
scheglov@google.com
3e857985dc
Report CTEC.CONST_WITH_NON_CONSTANT_ARGUMENT
...
R=brianwilkerson@google.com , jwren@google.com
BUG=
Review URL: https://codereview.chromium.org//14861012
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22646 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-13 19:45:48 +00:00
fschneider@google.com
8ad125f607
Optimize functions containing try-catch.
...
This is a first step towards fully optimizing try-catch-finally.
At a catch entry, all local variables and parameters are
expected at a fixed stack location. There is a list of
initial definitions at the catch entry block, similar to
the initial definitions at graph entry.
Inside every try-block there is a special prologue code before each
call (instruction that may throw) inside the try-block. This prologue
is similar to a parallel move instruction: It moves all locals+parameters
to the locations expected by the catch-entry block. The stack frame
is extended with the corresponding number of fixed slots right below
the normal spill slots.
Every function containing try-catch has additional compiler-
generated local variables to pass the context, the exception and
the stack trace.
Variable liveness analysis is adapted to treat locals inside try{} blocks
specially: Every call has an implicit LoadLocal of every local variable.
This CL uses a safe approximiation of liveness which can be optimized further.
Current restrictions which are planned for future CLs:
* No inlining inside try-blocks.
* No inlining of functions containing try-catch.
* No try-finally yet.
R=kmillikin@google.com
Review URL: https://codereview.chromium.org//14682020
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22615 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-13 10:33:24 +00:00