OLD | NEW |
1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2013, 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 // Generate a snapshot file after loading all the scripts specified on the | 5 // Generate a snapshot file after loading all the scripts specified on the |
6 // command line. | 6 // command line. |
7 | 7 |
8 #include <stdlib.h> | 8 #include <stdlib.h> |
9 #include <string.h> | 9 #include <string.h> |
10 #include <stdio.h> | 10 #include <stdio.h> |
(...skipping 1014 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1025 } | 1025 } |
1026 | 1026 |
1027 Dart_SetVMFlags(vm_options.count(), vm_options.arguments()); | 1027 Dart_SetVMFlags(vm_options.count(), vm_options.arguments()); |
1028 | 1028 |
1029 // Initialize the Dart VM. | 1029 // Initialize the Dart VM. |
1030 // Note: We don't expect isolates to be created from dart code during | 1030 // Note: We don't expect isolates to be created from dart code during |
1031 // snapshot generation. | 1031 // snapshot generation. |
1032 char* error = Dart_Initialize( | 1032 char* error = Dart_Initialize( |
1033 NULL, | 1033 NULL, |
1034 NULL, | 1034 NULL, |
| 1035 NULL, |
1035 CreateServiceIsolate, | 1036 CreateServiceIsolate, |
1036 NULL, | 1037 NULL, |
1037 NULL, | 1038 NULL, |
1038 NULL, | 1039 NULL, |
1039 DartUtils::OpenFile, | 1040 DartUtils::OpenFile, |
1040 DartUtils::ReadFile, | 1041 DartUtils::ReadFile, |
1041 DartUtils::WriteFile, | 1042 DartUtils::WriteFile, |
1042 DartUtils::CloseFile, | 1043 DartUtils::CloseFile, |
1043 DartUtils::EntropySource, | 1044 DartUtils::EntropySource, |
1044 NULL); | 1045 NULL); |
(...skipping 96 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1141 EventHandler::Stop(); | 1142 EventHandler::Stop(); |
1142 return 0; | 1143 return 0; |
1143 } | 1144 } |
1144 | 1145 |
1145 } // namespace bin | 1146 } // namespace bin |
1146 } // namespace dart | 1147 } // namespace dart |
1147 | 1148 |
1148 int main(int argc, char** argv) { | 1149 int main(int argc, char** argv) { |
1149 return dart::bin::main(argc, argv); | 1150 return dart::bin::main(argc, argv); |
1150 } | 1151 } |
OLD | NEW |