OLD | NEW |
1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2013, 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 "include/dart_api.h" | 5 #include "include/dart_api.h" |
6 | 6 |
7 #include "platform/assert.h" | 7 #include "platform/assert.h" |
8 #include "vm/bigint_operations.h" | 8 #include "vm/bigint_operations.h" |
9 #include "vm/class_finalizer.h" | 9 #include "vm/class_finalizer.h" |
10 #include "vm/compiler.h" | 10 #include "vm/compiler.h" |
(...skipping 2424 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2435 return GetType(class_id); | 2435 return GetType(class_id); |
2436 } | 2436 } |
2437 return kInvalid; | 2437 return kInvalid; |
2438 } | 2438 } |
2439 | 2439 |
2440 | 2440 |
2441 static RawObject* GetByteDataConstructor(Isolate* isolate, | 2441 static RawObject* GetByteDataConstructor(Isolate* isolate, |
2442 const String& constructor_name, | 2442 const String& constructor_name, |
2443 intptr_t num_args) { | 2443 intptr_t num_args) { |
2444 const Library& lib = | 2444 const Library& lib = |
2445 Library::Handle(isolate->object_store()->typeddata_library()); | 2445 Library::Handle(isolate->object_store()->typed_data_library()); |
2446 ASSERT(!lib.IsNull()); | 2446 ASSERT(!lib.IsNull()); |
2447 const Class& cls = | 2447 const Class& cls = |
2448 Class::Handle(isolate, lib.LookupClassAllowPrivate(Symbols::ByteData())); | 2448 Class::Handle(isolate, lib.LookupClassAllowPrivate(Symbols::ByteData())); |
2449 ASSERT(!cls.IsNull()); | 2449 ASSERT(!cls.IsNull()); |
2450 return ResolveConstructor(CURRENT_FUNC, | 2450 return ResolveConstructor(CURRENT_FUNC, |
2451 cls, | 2451 cls, |
2452 Symbols::ByteData(), | 2452 Symbols::ByteData(), |
2453 constructor_name, | 2453 constructor_name, |
2454 num_args); | 2454 num_args); |
2455 } | 2455 } |
(...skipping 2390 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4846 } | 4846 } |
4847 { | 4847 { |
4848 NoGCScope no_gc; | 4848 NoGCScope no_gc; |
4849 RawObject* raw_obj = obj.raw(); | 4849 RawObject* raw_obj = obj.raw(); |
4850 isolate->heap()->SetPeer(raw_obj, peer); | 4850 isolate->heap()->SetPeer(raw_obj, peer); |
4851 } | 4851 } |
4852 return Api::Success(isolate); | 4852 return Api::Success(isolate); |
4853 } | 4853 } |
4854 | 4854 |
4855 } // namespace dart | 4855 } // namespace dart |
OLD | NEW |