| OLD | NEW |
| 1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2011, 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 "vm/dart_entry.h" | 5 #include "vm/dart_entry.h" |
| 6 | 6 |
| 7 #include "vm/class_finalizer.h" | 7 #include "vm/class_finalizer.h" |
| 8 #include "vm/code_generator.h" | 8 #include "vm/code_generator.h" |
| 9 #include "vm/compiler.h" | 9 #include "vm/compiler.h" |
| 10 #include "vm/debugger.h" | 10 #include "vm/debugger.h" |
| (...skipping 231 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 242 return InvokeFunction(function, args); | 242 return InvokeFunction(function, args); |
| 243 } | 243 } |
| 244 | 244 |
| 245 | 245 |
| 246 ArgumentsDescriptor::ArgumentsDescriptor(const Array& array) | 246 ArgumentsDescriptor::ArgumentsDescriptor(const Array& array) |
| 247 : array_(array) { | 247 : array_(array) { |
| 248 } | 248 } |
| 249 | 249 |
| 250 | 250 |
| 251 intptr_t ArgumentsDescriptor::Count() const { | 251 intptr_t ArgumentsDescriptor::Count() const { |
| 252 return Smi::CheckedHandle(array_.At(kCountIndex)).Value(); | 252 return Smi::Cast(Object::Handle(array_.At(kCountIndex))).Value(); |
| 253 } | 253 } |
| 254 | 254 |
| 255 | 255 |
| 256 intptr_t ArgumentsDescriptor::PositionalCount() const { | 256 intptr_t ArgumentsDescriptor::PositionalCount() const { |
| 257 return Smi::CheckedHandle(array_.At(kPositionalCountIndex)).Value(); | 257 return Smi::Cast(Object::Handle(array_.At(kPositionalCountIndex))).Value(); |
| 258 } | 258 } |
| 259 | 259 |
| 260 | 260 |
| 261 RawString* ArgumentsDescriptor::NameAt(intptr_t index) const { | 261 RawString* ArgumentsDescriptor::NameAt(intptr_t index) const { |
| 262 const intptr_t offset = kFirstNamedEntryIndex + | 262 const intptr_t offset = kFirstNamedEntryIndex + |
| 263 (index * kNamedEntrySize) + | 263 (index * kNamedEntrySize) + |
| 264 kNameOffset; | 264 kNameOffset; |
| 265 String& result = String::Handle(); | 265 String& result = String::Handle(); |
| 266 result ^= array_.At(offset); | 266 result ^= array_.At(offset); |
| 267 return result.raw(); | 267 return result.raw(); |
| (...skipping 308 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 576 const Array& args = Array::Handle(Array::New(kNumArguments)); | 576 const Array& args = Array::Handle(Array::New(kNumArguments)); |
| 577 args.SetAt(0, map); | 577 args.SetAt(0, map); |
| 578 args.SetAt(1, key); | 578 args.SetAt(1, key); |
| 579 args.SetAt(2, value); | 579 args.SetAt(2, value); |
| 580 const Object& result = Object::Handle(DartEntry::InvokeFunction(function, | 580 const Object& result = Object::Handle(DartEntry::InvokeFunction(function, |
| 581 args)); | 581 args)); |
| 582 return result.raw(); | 582 return result.raw(); |
| 583 } | 583 } |
| 584 | 584 |
| 585 } // namespace dart | 585 } // namespace dart |
| OLD | NEW |