| OLD | NEW |
| 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 "vm/flow_graph_builder.h" | 5 #include "vm/flow_graph_builder.h" |
| 6 | 6 |
| 7 #include "lib/invocation_mirror.h" | 7 #include "lib/invocation_mirror.h" |
| 8 #include "vm/ast_printer.h" | 8 #include "vm/ast_printer.h" |
| 9 #include "vm/bit_vector.h" | 9 #include "vm/bit_vector.h" |
| 10 #include "vm/code_descriptors.h" | 10 #include "vm/code_descriptors.h" |
| (...skipping 3400 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3411 Value* argument_names_value = | 3411 Value* argument_names_value = |
| 3412 Bind(new ConstantInstr(Array::ZoneHandle())); | 3412 Bind(new ConstantInstr(Array::ZoneHandle())); |
| 3413 arguments->Add(PushArgument(argument_names_value)); | 3413 arguments->Add(PushArgument(argument_names_value)); |
| 3414 // List existingArgumentNames. | 3414 // List existingArgumentNames. |
| 3415 Value* existing_argument_names_value = | 3415 Value* existing_argument_names_value = |
| 3416 Bind(new ConstantInstr(Array::ZoneHandle())); | 3416 Bind(new ConstantInstr(Array::ZoneHandle())); |
| 3417 arguments->Add(PushArgument(existing_argument_names_value)); | 3417 arguments->Add(PushArgument(existing_argument_names_value)); |
| 3418 // Resolve and call NoSuchMethodError._throwNew. | 3418 // Resolve and call NoSuchMethodError._throwNew. |
| 3419 const Library& core_lib = Library::Handle(Library::CoreLibrary()); | 3419 const Library& core_lib = Library::Handle(Library::CoreLibrary()); |
| 3420 const Class& cls = Class::Handle( | 3420 const Class& cls = Class::Handle( |
| 3421 core_lib.LookupClass(Symbols::NoSuchMethodError())); | 3421 core_lib.LookupClass(Symbols::NoSuchMethodError(), NULL)); |
| 3422 ASSERT(!cls.IsNull()); | 3422 ASSERT(!cls.IsNull()); |
| 3423 const Function& func = Function::ZoneHandle( | 3423 const Function& func = Function::ZoneHandle( |
| 3424 Resolver::ResolveStatic(cls, | 3424 Resolver::ResolveStatic(cls, |
| 3425 PrivateCoreLibName(Symbols::ThrowNew()), | 3425 PrivateCoreLibName(Symbols::ThrowNew()), |
| 3426 arguments->length(), | 3426 arguments->length(), |
| 3427 Object::null_array(), | 3427 Object::null_array(), |
| 3428 Resolver::kIsQualified)); | 3428 Resolver::kIsQualified)); |
| 3429 ASSERT(!func.IsNull()); | 3429 ASSERT(!func.IsNull()); |
| 3430 return new StaticCallInstr(token_pos, | 3430 return new StaticCallInstr(token_pos, |
| 3431 func, | 3431 func, |
| (...skipping 122 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3554 intptr_t len = OS::SNPrint(NULL, 0, kFormat, function_name, reason) + 1; | 3554 intptr_t len = OS::SNPrint(NULL, 0, kFormat, function_name, reason) + 1; |
| 3555 char* chars = Isolate::Current()->current_zone()->Alloc<char>(len); | 3555 char* chars = Isolate::Current()->current_zone()->Alloc<char>(len); |
| 3556 OS::SNPrint(chars, len, kFormat, function_name, reason); | 3556 OS::SNPrint(chars, len, kFormat, function_name, reason); |
| 3557 const Error& error = Error::Handle( | 3557 const Error& error = Error::Handle( |
| 3558 LanguageError::New(String::Handle(String::New(chars)))); | 3558 LanguageError::New(String::Handle(String::New(chars)))); |
| 3559 Isolate::Current()->long_jump_base()->Jump(1, error); | 3559 Isolate::Current()->long_jump_base()->Jump(1, error); |
| 3560 } | 3560 } |
| 3561 | 3561 |
| 3562 | 3562 |
| 3563 } // namespace dart | 3563 } // namespace dart |
| OLD | NEW |