Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(212)

Side by Side Diff: vm/object_test.cc

Issue 10782016: Enforce length/size limits for variable size heap object in order to (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/runtime/
Patch Set: Created 8 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « vm/object.cc ('k') | vm/os.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 #include "platform/assert.h" 5 #include "platform/assert.h"
6 #include "vm/assembler.h" 6 #include "vm/assembler.h"
7 #include "vm/bigint_operations.h" 7 #include "vm/bigint_operations.h"
8 #include "vm/isolate.h" 8 #include "vm/isolate.h"
9 #include "vm/object.h" 9 #include "vm/object.h"
10 #include "vm/object_store.h" 10 #include "vm/object_store.h"
(...skipping 2779 matching lines...) Expand 10 before | Expand all | Expand 10 after
2790 bare_name = OneByteString::New("foo.named"); 2790 bare_name = OneByteString::New("foo.named");
2791 EXPECT(!mangled_name.EqualsIgnoringPrivateKey(bare_name)); 2791 EXPECT(!mangled_name.EqualsIgnoringPrivateKey(bare_name));
2792 2792
2793 // Named double-private constructor mismatch. 2793 // Named double-private constructor mismatch.
2794 mangled_name = OneByteString::New("foo@12345.named@12345"); 2794 mangled_name = OneByteString::New("foo@12345.named@12345");
2795 bare_name = OneByteString::New("foo.name"); 2795 bare_name = OneByteString::New("foo.name");
2796 EXPECT(!mangled_name.EqualsIgnoringPrivateKey(bare_name)); 2796 EXPECT(!mangled_name.EqualsIgnoringPrivateKey(bare_name));
2797 } 2797 }
2798 2798
2799 2799
2800 TEST_CASE(ArrayNew_Overflow_Crash) {
2801 Array::Handle(Array::New(Array::kMaxElements + 1));
2802 }
2803
2804
2800 #endif // defined(TARGET_ARCH_IA32) || defined(TARGET_ARCH_X64). 2805 #endif // defined(TARGET_ARCH_IA32) || defined(TARGET_ARCH_X64).
2801 2806
2802 } // namespace dart 2807 } // namespace dart
OLDNEW
« no previous file with comments | « vm/object.cc ('k') | vm/os.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698