| 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/block_scheduler.h" | 10 #include "vm/block_scheduler.h" |
| (...skipping 1462 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1473 // Function fits the bill. | 1473 // Function fits the bill. |
| 1474 const char* kEvalConst = "eval_const"; | 1474 const char* kEvalConst = "eval_const"; |
| 1475 const Function& func = Function::ZoneHandle(Function::New( | 1475 const Function& func = Function::ZoneHandle(Function::New( |
| 1476 String::Handle(Symbols::New(kEvalConst)), | 1476 String::Handle(Symbols::New(kEvalConst)), |
| 1477 RawFunction::kRegularFunction, | 1477 RawFunction::kRegularFunction, |
| 1478 true, // static function | 1478 true, // static function |
| 1479 false, // not const function | 1479 false, // not const function |
| 1480 false, // not abstract | 1480 false, // not abstract |
| 1481 false, // not external | 1481 false, // not external |
| 1482 false, // not native | 1482 false, // not native |
| 1483 Class::Handle(Type::Handle(Type::Function()).type_class()), | 1483 Class::Handle(Type::Handle(Type::DartFunctionType()).type_class()), |
| 1484 fragment->token_pos())); | 1484 fragment->token_pos())); |
| 1485 | 1485 |
| 1486 func.set_result_type(Object::dynamic_type()); | 1486 func.set_result_type(Object::dynamic_type()); |
| 1487 func.set_num_fixed_parameters(0); | 1487 func.set_num_fixed_parameters(0); |
| 1488 func.SetNumOptionalParameters(0, true); | 1488 func.SetNumOptionalParameters(0, true); |
| 1489 // Manually generated AST, do not recompile. | 1489 // Manually generated AST, do not recompile. |
| 1490 func.SetIsOptimizable(false); | 1490 func.SetIsOptimizable(false); |
| 1491 func.set_is_debuggable(false); | 1491 func.set_is_debuggable(false); |
| 1492 | 1492 |
| 1493 // We compile the function here, even though InvokeFunction() below | 1493 // We compile the function here, even though InvokeFunction() below |
| (...skipping 389 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1883 } | 1883 } |
| 1884 | 1884 |
| 1885 | 1885 |
| 1886 void BackgroundCompiler::EnsureInit(Thread* thread) { | 1886 void BackgroundCompiler::EnsureInit(Thread* thread) { |
| 1887 UNREACHABLE(); | 1887 UNREACHABLE(); |
| 1888 } | 1888 } |
| 1889 | 1889 |
| 1890 #endif // DART_PRECOMPILED_RUNTIME | 1890 #endif // DART_PRECOMPILED_RUNTIME |
| 1891 | 1891 |
| 1892 } // namespace dart | 1892 } // namespace dart |
| OLD | NEW |