| 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/compiler.h" | 5 #include "vm/compiler.h" |
| 6 | 6 |
| 7 #include "vm/assembler.h" | 7 #include "vm/assembler.h" |
| 8 #include "vm/ast_printer.h" | 8 #include "vm/ast_printer.h" |
| 9 #include "vm/code_generator.h" | 9 #include "vm/code_generator.h" |
| 10 #include "vm/code_index_table.h" | 10 #include "vm/code_index_table.h" |
| (...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 60 all_nodes[n]->SetIcDataArrayAtId(node_id, *arrays[i]); | 60 all_nodes[n]->SetIcDataArrayAtId(node_id, *arrays[i]); |
| 61 } | 61 } |
| 62 } | 62 } |
| 63 ASSERT(found_node); | 63 ASSERT(found_node); |
| 64 } | 64 } |
| 65 } | 65 } |
| 66 | 66 |
| 67 | 67 |
| 68 void Compiler::Compile(const Library& library, const Script& script) { | 68 void Compiler::Compile(const Library& library, const Script& script) { |
| 69 if (FLAG_trace_compiler) { | 69 if (FLAG_trace_compiler) { |
| 70 HANDLESCOPE(); | 70 HANDLESCOPE(Isolate::Current()); |
| 71 const String& script_url = String::Handle(script.url()); | 71 const String& script_url = String::Handle(script.url()); |
| 72 // TODO(iposva): Extract script kind. | 72 // TODO(iposva): Extract script kind. |
| 73 OS::Print("Compiling %s '%s'\n", "", script_url.ToCString()); | 73 OS::Print("Compiling %s '%s'\n", "", script_url.ToCString()); |
| 74 } | 74 } |
| 75 const String& library_key = String::Handle(library.private_key()); | 75 const String& library_key = String::Handle(library.private_key()); |
| 76 script.Tokenize(library_key); | 76 script.Tokenize(library_key); |
| 77 Parser::ParseCompilationUnit(library, script); | 77 Parser::ParseCompilationUnit(library, script); |
| 78 } | 78 } |
| 79 | 79 |
| 80 | 80 |
| (...skipping 183 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 264 kNoArgumentNames)); | 264 kNoArgumentNames)); |
| 265 if (result.IsUnhandledException()) { | 265 if (result.IsUnhandledException()) { |
| 266 // TODO(srdjan): implement proper exit from compiler. | 266 // TODO(srdjan): implement proper exit from compiler. |
| 267 UNIMPLEMENTED(); | 267 UNIMPLEMENTED(); |
| 268 } | 268 } |
| 269 return result.raw(); | 269 return result.raw(); |
| 270 } | 270 } |
| 271 | 271 |
| 272 | 272 |
| 273 } // namespace dart | 273 } // namespace dart |
| OLD | NEW |