Commit Graph

1846 Commits

Author SHA1 Message Date
karlklose@google.com 54538f6161 Generate a warning and a runtime error for calls to nonexistent static calls, getters and setters.
R=ngeoffray@google.com
BUG=3086,3089,3095

Review URL: https://chromiumcodereview.appspot.com//10920089

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@12011 260f80e4-7a28-3924-810f-c04153c831b5
2012-09-07 10:41:38 +00:00
regis@google.com 7cc84c2892 Implement new optional parameters syntax in the vm (issue 4290).
Provide --reject_named_argument_as_positional flag to ease transition to new
syntax (default is false).
Add tests.
Review URL: https://chromiumcodereview.appspot.com//10910119

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@12004 260f80e4-7a28-3924-810f-c04153c831b5
2012-09-07 01:13:27 +00:00
hausner@google.com 9247c4bd0b Fix dart2dart status
Review URL: https://chromiumcodereview.appspot.com//10917116

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11975 260f80e4-7a28-3924-810f-c04153c831b5
2012-09-06 18:32:35 +00:00
hausner@google.com ae1c248f3a Update dartc status file
TBR
Review URL: https://chromiumcodereview.appspot.com//10905135

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11974 260f80e4-7a28-3924-810f-c04153c831b5
2012-09-06 18:22:19 +00:00
ngeoffray@google.com 7ef6d7aac2 Re-apply with a few fixes http://codereview.chromium.org/10913081/: Fix resolution of type parameters in static context, and the use of type parameters in closures.
Review URL: https://chromiumcodereview.appspot.com//10910098

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11966 260f80e4-7a28-3924-810f-c04153c831b5
2012-09-06 16:31:30 +00:00
ngeoffray@google.com b5fe256172 Improvements for checked mode: check when intializing fields, and when assigning to fields.
Review URL: https://chromiumcodereview.appspot.com//10910092

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11962 260f80e4-7a28-3924-810f-c04153c831b5
2012-09-06 16:03:25 +00:00
ngeoffray@google.com 2edbe0b892 Revert r11881. metadata_test fails for yet to be discover reasons.
Review URL: https://chromiumcodereview.appspot.com//10918078

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11889 260f80e4-7a28-3924-810f-c04153c831b5
2012-09-05 17:04:38 +00:00
ngeoffray@google.com f1aece76c4 Fix resolution of type parameters in static context, and the use of type parameters in closures.
Review URL: https://chromiumcodereview.appspot.com//10913081

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11881 260f80e4-7a28-3924-810f-c04153c831b5
2012-09-05 16:04:25 +00:00
scheglov@google.com 6f8893f9b8 Invocation C.unknownMethod() should produce warning, not error
R=brianwilkerson@google.com
BUG=

Review URL: https://chromiumcodereview.appspot.com//10914099

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11878 260f80e4-7a28-3924-810f-c04153c831b5
2012-09-05 15:58:18 +00:00
floitsch@google.com 7a243f0d40 Fix type-annotation and add another tests.
Review URL: https://chromiumcodereview.appspot.com//10914097

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11874 260f80e4-7a28-3924-810f-c04153c831b5
2012-09-05 12:19:21 +00:00
floitsch@google.com c620a56249 Update status file.
Review URL: https://chromiumcodereview.appspot.com//10918070

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11872 260f80e4-7a28-3924-810f-c04153c831b5
2012-09-05 11:59:54 +00:00
floitsch@google.com ec7343beaa Fix tests and update status files.
Review URL: https://chromiumcodereview.appspot.com//10909081

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11871 260f80e4-7a28-3924-810f-c04153c831b5
2012-09-05 11:52:24 +00:00
floitsch@google.com a0f8e3db29 Lazy implementation of final variables.
Fixes issue 3559.

Depends on CL https://chromiumcodereview.appspot.com/10832351/

Review URL: https://chromiumcodereview.appspot.com//10855174

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11870 260f80e4-7a28-3924-810f-c04153c831b5
2012-09-05 11:28:38 +00:00
regis@google.com a7c80bc141 Disable test failing in minified tests of dart2dart.
Review URL: https://chromiumcodereview.appspot.com//10911071

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11837 260f80e4-7a28-3924-810f-c04153c831b5
2012-09-04 19:34:57 +00:00
regis@google.com 2ea2249b48 Fix argument definition test (issue 4888).
Review URL: https://chromiumcodereview.appspot.com//10907064

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11835 260f80e4-7a28-3924-810f-c04153c831b5
2012-09-04 18:59:01 +00:00
brianwilkerson@google.com efaa2a1d4b Old catch syntax is now an error (issue 4905)
Review URL: https://chromiumcodereview.appspot.com//10913068

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11834 260f80e4-7a28-3924-810f-c04153c831b5
2012-09-04 18:11:19 +00:00
ngeoffray@google.com abf87c420c Triage test.
Review URL: https://chromiumcodereview.appspot.com//10916092

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11822 260f80e4-7a28-3924-810f-c04153c831b5
2012-09-04 15:12:41 +00:00
antonm@google.com bedfbc7738 It both fails and crashes.
TBR=ngeoffray@google.com

Review URL: https://chromiumcodereview.appspot.com//10917073

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11818 260f80e4-7a28-3924-810f-c04153c831b5
2012-09-04 13:59:48 +00:00
antonm@google.com f81545d756 Mark test as crashing.
TBR=ngeoffray@google.com

Review URL: https://chromiumcodereview.appspot.com//10915060

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11817 260f80e4-7a28-3924-810f-c04153c831b5
2012-09-04 13:45:55 +00:00
antonm@google.com 6c1cd8f109 Suppress a test as this feature is not supported by DartVM yet.
TBR=ngeoffray@google.com

Review URL: https://chromiumcodereview.appspot.com//10907058

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11816 260f80e4-7a28-3924-810f-c04153c831b5
2012-09-04 13:43:05 +00:00
ngeoffray@google.com 63a2bfbe48 Codegen support for the argument definition test.
Review URL: https://chromiumcodereview.appspot.com//10911062

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11814 260f80e4-7a28-3924-810f-c04153c831b5
2012-09-04 13:22:09 +00:00
kasperl@google.com d5c89fec05 Allow the analyzer to fail a few new tests.
TBR'ed.

R=brianwilkerson@google.com
BUG=

Review URL: https://chromiumcodereview.appspot.com//10909058

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11808 260f80e4-7a28-3924-810f-c04153c831b5
2012-09-04 12:34:48 +00:00
ngeoffray@google.com c4d0fdde5c Fix dartc bot.
Review URL: https://chromiumcodereview.appspot.com//10920071

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11793 260f80e4-7a28-3924-810f-c04153c831b5
2012-09-04 08:40:50 +00:00
ngeoffray@google.com fee082d1f3 Fix issue 4361 by checking in the resolver if the getter/setter exists.
Review URL: https://chromiumcodereview.appspot.com//10905062

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11792 260f80e4-7a28-3924-810f-c04153c831b5
2012-09-04 08:28:16 +00:00
ngeoffray@google.com f9fd519fe7 Fix dart2dart bot.
Review URL: https://chromiumcodereview.appspot.com//10911060

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11790 260f80e4-7a28-3924-810f-c04153c831b5
2012-09-04 07:50:44 +00:00
ngeoffray@google.com 22c6f370ca Allow access to super fields inside a closure.
Review URL: https://chromiumcodereview.appspot.com//10916079

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11786 260f80e4-7a28-3924-810f-c04153c831b5
2012-09-04 07:28:19 +00:00
hausner@google.com 4987ff9cd9 Sheesh...
Review URL: https://chromiumcodereview.appspot.com//10910042

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11713 260f80e4-7a28-3924-810f-c04153c831b5
2012-08-31 18:56:09 +00:00
hausner@google.com 067a15e4a8 Fix remaining dartc test status
Review URL: https://chromiumcodereview.appspot.com//10916061

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11712 260f80e4-7a28-3924-810f-c04153c831b5
2012-08-31 18:37:37 +00:00
hausner@google.com 21ac7581d8 Fis dart2dart test status
Review URL: https://chromiumcodereview.appspot.com//10924002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11711 260f80e4-7a28-3924-810f-c04153c831b5
2012-08-31 18:33:33 +00:00
hausner@google.com 35d7793891 Throw AbstractClassInstantiationError if an abstract class is instantiated
This is the second try to my previous attempt to implement the
new abstract class handling. Instead of a compile-time error,
the VM now throws an AbstractClassInstantiationError at runtime
if an abstract class is instantiated. Added the new error class
to the core library.

For now I'm still using the rule that a class is abstract if it is explicitly
marked as abstract, or if it defines a new abstract method.
Review URL: https://chromiumcodereview.appspot.com//10916039

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11708 260f80e4-7a28-3924-810f-c04153c831b5
2012-08-31 18:06:42 +00:00
regis@google.com 9e00bd8ccb Implement argument definition test in the vm.
Add tests.
Various cleanups.
Review URL: https://chromiumcodereview.appspot.com//10915022

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11664 260f80e4-7a28-3924-810f-c04153c831b5
2012-08-30 22:46:44 +00:00
brianwilkerson@google.com 3c3badd039 Accept types rather than identifiers in catch clauses (Issue 4840)
Review URL: https://chromiumcodereview.appspot.com//10913016

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11660 260f80e4-7a28-3924-810f-c04153c831b5
2012-08-30 21:30:05 +00:00
ager@google.com 516b9ffeee Fix language.status
R=antonm@google.com
BUG=

Review URL: https://chromiumcodereview.appspot.com//10905014

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11608 260f80e4-7a28-3924-810f-c04153c831b5
2012-08-30 11:52:34 +00:00
ager@google.com 178100ded4 Move print to corelib.
Allow embedder customization in the VM through a static field that can
be set by the embedder.

Mark failing test that is unrelated to this change. The VM does not
like when you import dart:core explicitly and tells you there both
'dart:core' and 'dart:core' define 'print'.

R=ajohnsen@google.com,iposva@google.com
BUG=

Review URL: https://chromiumcodereview.appspot.com//10887024

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11603 260f80e4-7a28-3924-810f-c04153c831b5
2012-08-30 11:31:30 +00:00
kasperl@google.com e8c8244882 Update test expectations.
R=floitsch@google.com
BUG=

Review URL: https://chromiumcodereview.appspot.com//10912006

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11596 260f80e4-7a28-3924-810f-c04153c831b5
2012-08-30 10:35:12 +00:00
kasperl@google.com befd13e306 Add test for final field initialization (fails on the VM).
R=ngeoffray@google.com
BUG=

Review URL: https://chromiumcodereview.appspot.com//10908007

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11593 260f80e4-7a28-3924-810f-c04153c831b5
2012-08-30 09:50:12 +00:00
aprelev@gmail.com fbc9100ad7 Fixed tests so they do indeed confirm that values on optional named parameters are not allowed. Added check to the dart2js parser, so that setting values on optional named parameters is flagged as error. Tests pass.
BUG=dart:351
TEST=

Review URL: https://chromiumcodereview.appspot.com//10800027

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11573 260f80e4-7a28-3924-810f-c04153c831b5
2012-08-30 02:03:42 +00:00
hausner@google.com b3a2c41d02 Revert change 11558
I learnt that instantiating an abstract class is a runtime error, not a compile time error.

TBR=regis
Review URL: https://chromiumcodereview.appspot.com//10894048

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11567 260f80e4-7a28-3924-810f-c04153c831b5
2012-08-29 22:49:52 +00:00
hausner@google.com a1f0e08b24 Fix dart2dart test status
Review URL: https://chromiumcodereview.appspot.com//10891046

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11561 260f80e4-7a28-3924-810f-c04153c831b5
2012-08-29 22:27:28 +00:00
hausner@google.com 28d88d4b2d Add compiler error when instantiating abstract class
Also, make abstract keyword on methods optional.
Review URL: https://chromiumcodereview.appspot.com//10899039

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11558 260f80e4-7a28-3924-810f-c04153c831b5
2012-08-29 22:13:06 +00:00
antonm@google.com dd9f61b912 Rename members and named constructors.
That also leads to renames of named arguments in some contexts like

class C {
  final f;
  C([this.f]);
}

new C(f: 42).

Now we need to change the name of named argument along with the field name.

R=smok@google.com

Review URL: https://chromiumcodereview.appspot.com//10887012

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11505 260f80e4-7a28-3924-810f-c04153c831b5
2012-08-29 10:13:00 +00:00
karlklose@google.com 544b754a7d Throw a runtime error when trying to call a constructor of a class that could not be resolved.
TESTS=language/call_constructor_on_unresolved_class_test
BUG=3802

Review URL: https://chromiumcodereview.appspot.com//10868069

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11497 260f80e4-7a28-3924-810f-c04153c831b5
2012-08-29 08:52:53 +00:00
scheglov@google.com 6ef7aa818d Issue 3904. Allow using class literal in expressions
http://code.google.com/p/dart/issues/detail?id=3904

R=brianwilkerson@google.com
BUG=

Review URL: https://chromiumcodereview.appspot.com//10873096

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11440 260f80e4-7a28-3924-810f-c04153c831b5
2012-08-28 13:16:21 +00:00
ngeoffray@google.com b32a0c9e68 Change how runtime type information is being set in the backend.
Review URL: https://chromiumcodereview.appspot.com//10888003

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11436 260f80e4-7a28-3924-810f-c04153c831b5
2012-08-28 10:59:53 +00:00
scheglov@google.com 618ff29a6d Issue 4713. Support for 'static const' field in interfaces
http://code.google.com/p/dart/issues/detail?id=4713

R=brianwilkerson@google.com
BUG=

Review URL: https://chromiumcodereview.appspot.com//10874089

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11409 260f80e4-7a28-3924-810f-c04153c831b5
2012-08-27 19:51:17 +00:00
iposva@google.com 161c6ba9bb - Update test status after rename.
Review URL: https://chromiumcodereview.appspot.com//10870086

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11352 260f80e4-7a28-3924-810f-c04153c831b5
2012-08-24 22:51:43 +00:00
ahe@google.com 785ff37496 Update dart2dart status after supporting abstract getters
Review URL: https://chromiumcodereview.appspot.com//10869045

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11294 260f80e4-7a28-3924-810f-c04153c831b5
2012-08-24 08:39:24 +00:00
ricow@google.com 5871d1e68d Update status file to use mac instead of macos.
Emily: why do we have these skip exceptions anyway, imho they don't make any sense at all (who has ie on linux or mac?). If there is no deeper meaning we should delete them.
Review URL: https://chromiumcodereview.appspot.com//10877010

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11287 260f80e4-7a28-3924-810f-c04153c831b5
2012-08-24 07:01:09 +00:00
ahe@google.com 52d2cb4431 Record literal list type arguments and report errors when there are too many.
Review URL: https://chromiumcodereview.appspot.com//10880026

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11286 260f80e4-7a28-3924-810f-c04153c831b5
2012-08-24 05:09:43 +00:00
ahe@google.com 65d3da757e Revert r10075, I'll follow up with a different solution.
Review URL: https://chromiumcodereview.appspot.com//10879039

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11236 260f80e4-7a28-3924-810f-c04153c831b5
2012-08-23 15:17:46 +00:00