| 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/bootstrap.h" | 5 #include "vm/bootstrap.h" |
| 6 | 6 |
| 7 #include "include/dart_api.h" | 7 #include "include/dart_api.h" |
| 8 | 8 |
| 9 #include "vm/bootstrap_natives.h" | 9 #include "vm/bootstrap_natives.h" |
| 10 #include "vm/class_finalizer.h" | 10 #include "vm/class_finalizer.h" |
| (...skipping 337 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 348 } | 348 } |
| 349 } | 349 } |
| 350 } | 350 } |
| 351 if (error.IsNull()) { | 351 if (error.IsNull()) { |
| 352 SetupNativeResolver(); | 352 SetupNativeResolver(); |
| 353 ClassFinalizer::ProcessPendingClasses(); | 353 ClassFinalizer::ProcessPendingClasses(); |
| 354 | 354 |
| 355 // Eagerly compile the _Closure class as it is the class of all closure | 355 // Eagerly compile the _Closure class as it is the class of all closure |
| 356 // instances. This allows us to just finalize function types | 356 // instances. This allows us to just finalize function types |
| 357 // without going through the hoops of trying to compile their scope class. | 357 // without going through the hoops of trying to compile their scope class. |
| 358 const Class& cls = | 358 Class& cls = |
| 359 Class::Handle(zone, isolate->object_store()->closure_class()); | 359 Class::Handle(zone, isolate->object_store()->closure_class()); |
| 360 Compiler::CompileClass(cls); | 360 Compiler::CompileClass(cls); |
| 361 // Eagerly compile Bool class, bool constants are used from within compiler. |
| 362 cls = isolate->object_store()->bool_class(); |
| 363 Compiler::CompileClass(cls); |
| 361 } | 364 } |
| 362 | 365 |
| 363 // Restore the library tag handler for the isolate. | 366 // Restore the library tag handler for the isolate. |
| 364 isolate->set_library_tag_handler(saved_tag_handler); | 367 isolate->set_library_tag_handler(saved_tag_handler); |
| 365 | 368 |
| 366 return error.raw(); | 369 return error.raw(); |
| 367 } | 370 } |
| 368 | 371 |
| 369 } // namespace dart | 372 } // namespace dart |
| OLD | NEW |