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/compiler.h" | 5 #include "vm/compiler.h" |
6 | 6 |
7 #include "vm/assembler.h" | 7 #include "vm/assembler.h" |
8 | 8 |
9 #include "vm/ast_printer.h" | 9 #include "vm/ast_printer.h" |
10 #include "vm/code_generator.h" | 10 #include "vm/code_generator.h" |
(...skipping 620 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
631 fragment->scope()->AddVariable(parsed_function->expression_temp_var()); | 631 fragment->scope()->AddVariable(parsed_function->expression_temp_var()); |
632 parsed_function->set_array_literal_var( | 632 parsed_function->set_array_literal_var( |
633 ParsedFunction::CreateArrayLiteralVar(0)); | 633 ParsedFunction::CreateArrayLiteralVar(0)); |
634 fragment->scope()->AddVariable(parsed_function->array_literal_var()); | 634 fragment->scope()->AddVariable(parsed_function->array_literal_var()); |
635 parsed_function->AllocateVariables(); | 635 parsed_function->AllocateVariables(); |
636 | 636 |
637 // Non-optimized code generator. | 637 // Non-optimized code generator. |
638 CompileParsedFunctionHelper(*parsed_function, false); | 638 CompileParsedFunctionHelper(*parsed_function, false); |
639 | 639 |
640 const Object& result = Object::Handle( | 640 const Object& result = Object::Handle( |
641 DartEntry::InvokeStatic(func, Object::empty_array())); | 641 DartEntry::InvokeFunction(func, Object::empty_array())); |
642 isolate->set_long_jump_base(base); | 642 isolate->set_long_jump_base(base); |
643 return result.raw(); | 643 return result.raw(); |
644 } else { | 644 } else { |
645 const Object& result = | 645 const Object& result = |
646 Object::Handle(isolate->object_store()->sticky_error()); | 646 Object::Handle(isolate->object_store()->sticky_error()); |
647 isolate->object_store()->clear_sticky_error(); | 647 isolate->object_store()->clear_sticky_error(); |
648 isolate->set_long_jump_base(base); | 648 isolate->set_long_jump_base(base); |
649 return result.raw(); | 649 return result.raw(); |
650 } | 650 } |
651 UNREACHABLE(); | 651 UNREACHABLE(); |
652 return Object::null(); | 652 return Object::null(); |
653 } | 653 } |
654 | 654 |
655 } // namespace dart | 655 } // namespace dart |
OLD | NEW |