Commit Graph

25 Commits

Author SHA1 Message Date
rmacnak@google.com 8bdc9b5696 Cleanup making Null a public class of dart:core in the VM. Remove special cases for Null in lookup and compile-time type tests.
BUG=http://dartbug.com/12364
R=asiva@google.com, regis@google.com

Review URL: https://codereview.chromium.org//22819005

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@26205 260f80e4-7a28-3924-810f-c04153c831b5
2013-08-15 18:34:23 +00:00
srdjan@google.com 1f31dcc424 Fix for running with --throw_on_javascript_int_overflow: recognize pattern (a << b) & mask and test for overflow only after the mask.
R=fschneider@google.com

Review URL: https://codereview.chromium.org//22640019

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@26122 260f80e4-7a28-3924-810f-c04153c831b5
2013-08-14 15:12:39 +00:00
iposva@google.com 56b0fc10a7 Reland r24563 and r24564 with fixes cumbersome API leading to leaks.
- Add a WeakTable to the VM. This is used to remember the
  native peers registered through the Dart C API as well
  as assigning identity hashcodes to objects when needed.
- Use the hashcode to lookup entries in the Expando.

Review URL: https://codereview.chromium.org//18826007

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@24822 260f80e4-7a28-3924-810f-c04153c831b5
2013-07-08 21:41:05 +00:00
iposva@google.com fb06bcdff3 - Revert r24564 and r24563 due to unexplained malloc corruption.
Review URL: https://codereview.chromium.org//18051007

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@24565 260f80e4-7a28-3924-810f-c04153c831b5
2013-06-28 00:27:25 +00:00
iposva@google.com 9c9989d2f6 - Add a WeakTable to the VM. This is used to remember the
native peers registered through the Dart C API as well
  as assigning identity hashcodes to objects when needed.
- Use the hashcode to lookup entries in the Expando.

R=asiva@google.com

Review URL: https://codereview.chromium.org//17992002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@24563 260f80e4-7a28-3924-810f-c04153c831b5
2013-06-28 00:01:47 +00:00
srdjan@google.com 7797d39362 Added Object._cid getter, optimized it. Added to (some) classes a static final _clCid. Use those to test for exact type in VM's libraries.
R=iposva@google.com

Review URL: https://codereview.chromium.org//14703005

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@22695 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-14 18:16:44 +00:00
ahe@google.com 89be2ccac8 Change memberName and namedArguments in Invocation to use Symbol.
Review URL: https://codereview.chromium.org//14066019

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@21602 260f80e4-7a28-3924-810f-c04153c831b5
2013-04-17 07:54:48 +00:00
ahe@google.com 5b6c0ba820 Rename InvocationMirror to Invocation.
Review URL: https://codereview.chromium.org//14049009

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@21465 260f80e4-7a28-3924-810f-c04153c831b5
2013-04-15 15:42:44 +00:00
srdjan@google.com 60e57ecfe1 Optimizes 'as' operation in similar way as 'instanceof': collect type feedback in unoptimized mode and try to convert it to a simple classcheck in optimized code.
Review URL: https://codereview.chromium.org//13190014

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@20783 260f80e4-7a28-3924-810f-c04153c831b5
2013-04-02 15:30:14 +00:00
iposva@google.com c900112af7 - Improve the message for NoSuchMethodErrors that are
determined statically at compile time.
Review URL: https://codereview.chromium.org//12328019

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@18848 260f80e4-7a28-3924-810f-c04153c831b5
2013-02-21 18:53:27 +00:00
iposva@google.com 2d8c51d0f4 Fix bug 5511:
- null must support hashCode.
Review URL: https://codereview.chromium.org//11819014

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@16827 260f80e4-7a28-3924-810f-c04153c831b5
2013-01-08 23:58:55 +00:00
srdjan@google.com 29e06db609 In unoptimized code use call for instanceof instead of inlined checks. This allows us to collect type feedback and to reduce the code size of unoptimized code. Next will be work on type tests as well.
Review URL: https://codereview.chromium.org//11694003

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@16589 260f80e4-7a28-3924-810f-c04153c831b5
2013-01-02 22:22:39 +00:00
regis@google.com 3b1dfe51d1 Pass the proper invocation mirror argument to noSuchMethod.
Review URL: https://codereview.chromium.org//11523002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@15939 260f80e4-7a28-3924-810f-c04153c831b5
2012-12-11 00:31:53 +00:00
lrn@google.com a8720a6d9c Change signature of noSuchMethod to take an InvocationMirror.
Requires VM and dart2js/dart2dart changes to work.

Committed: https://code.google.com/p/dart/source/detail?r=14198

Committed: https://code.google.com/p/dart/source/detail?r=14254

Review URL: https://codereview.chromium.org//11231074

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@14324 260f80e4-7a28-3924-810f-c04153c831b5
2012-10-31 10:32:54 +00:00
lrn@google.com 895d155ab1 Revert "Change signature of noSuchMethod to take an InvocationMirror."
TBR=ager@google.com

Review URL: https://codereview.chromium.org//11339042

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@14260 260f80e4-7a28-3924-810f-c04153c831b5
2012-10-30 10:47:42 +00:00
lrn@google.com 4a24ddc1d4 Change signature of noSuchMethod to take an InvocationMirror.
Requires VM and dart2js/dart2dart changes to work.

Committed: https://code.google.com/p/dart/source/detail?r=14198

Review URL: https://codereview.chromium.org//11231074

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@14254 260f80e4-7a28-3924-810f-c04153c831b5
2012-10-30 10:04:12 +00:00
lrn@google.com 778b0dc5e5 Revert "Change signature of noSuchMethod to take an InvocationMirror."
TBR=floitsch@google.com

Review URL: https://codereview.chromium.org//11336011

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@14199 260f80e4-7a28-3924-810f-c04153c831b5
2012-10-29 14:07:10 +00:00
lrn@google.com 0bcd2f4f7b Change signature of noSuchMethod to take an InvocationMirror.
Requires VM and dart2js/dart2dart changes to work.

Review URL: https://codereview.chromium.org//11231074

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@14198 260f80e4-7a28-3924-810f-c04153c831b5
2012-10-29 13:34:58 +00:00
floitsch@google.com 9074fd0178 Make hashCode a getter and not a method.
Review URL: https://codereview.chromium.org//11191078

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@13866 260f80e4-7a28-3924-810f-c04153c831b5
2012-10-22 12:41:04 +00:00
iposva@google.com b85f604f66 - Implement first class types in the VM.
- Make AbstractType a subclass of Instance and map it and its subclasses
  to private Dart classes in dart:core implementing the Type interface.
- Avoid dispatching through statics in Object if not strictly needed.
Review URL: https://codereview.chromium.org//10979058

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@12981 260f80e4-7a28-3924-810f-c04153c831b5
2012-09-27 21:19:00 +00:00
lrn@google.com ae0d6fca62 Ensure that hashCode and runtimeType work on null.
BUG=5510

Review URL: https://codereview.chromium.org//10979050

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@12948 260f80e4-7a28-3924-810f-c04153c831b5
2012-09-27 11:38:16 +00:00
ager@google.com 02b566ee62 Add documentation to the Object class in the core library.
R=lrn@google.com
BUG=

Review URL: https://codereview.chromium.org//10974004

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@12770 260f80e4-7a28-3924-810f-c04153c831b5
2012-09-24 11:07:34 +00:00
iposva@google.com eee4bbc1ef - Add definition of "int hashCode()" to Object.
- Implement hashCode in the VM.
- Mark hashCode as unimplemented in dart2js.
- Update test using the identity hashcode.
Review URL: https://codereview.chromium.org//10956026

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@12669 260f80e4-7a28-3924-810f-c04153c831b5
2012-09-21 00:32:58 +00:00
ager@google.com 156e6a71b5 First corelib cleanup patch after unification.
Do not go through coreimpl for object implementation. Instead, use patching
in core directly.

This leads to error message issues in dart2js which I have patched up
the best way I could find.

R=ajohnsen@google.com,johnniwinther@google.com,lrn@google.com
BUG=

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11784 260f80e4-7a28-3924-810f-c04153c831b5
2012-09-04 07:26:02 +00:00
ager@google.com 1cf5d4cc4b Unify Object implementation across dart2js and VM.
R=ajohnsen@google.com,lrn@google.com
BUG=

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

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@11372 260f80e4-7a28-3924-810f-c04153c831b5
2012-08-27 08:54:55 +00:00