| 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 <stdlib.h> | 5 #include <stdlib.h> |
| 6 #include <string.h> | 6 #include <string.h> |
| 7 #include <stdio.h> | 7 #include <stdio.h> |
| 8 | 8 |
| 9 #include "include/dart_api.h" | 9 #include "include/dart_api.h" |
| 10 #include "include/dart_tools_api.h" | 10 #include "include/dart_tools_api.h" |
| (...skipping 892 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 903 } | 903 } |
| 904 | 904 |
| 905 // Setup package root if specified. | 905 // Setup package root if specified. |
| 906 result = DartUtils::SetupPackageRoot(package_root, packages_config); | 906 result = DartUtils::SetupPackageRoot(package_root, packages_config); |
| 907 CHECK_RESULT(result); | 907 CHECK_RESULT(result); |
| 908 | 908 |
| 909 result = Dart_SetEnvironmentCallback(EnvironmentCallback); | 909 result = Dart_SetEnvironmentCallback(EnvironmentCallback); |
| 910 CHECK_RESULT(result); | 910 CHECK_RESULT(result); |
| 911 | 911 |
| 912 if (!Dart_IsKernelIsolate(isolate) && use_dart_frontend) { | 912 if (!Dart_IsKernelIsolate(isolate) && use_dart_frontend) { |
| 913 Log::PrintErr("Waiting for Kernel isolate to load.\n"); | |
| 914 // This must be the main script to be loaded. Wait for Kernel isolate | 913 // This must be the main script to be loaded. Wait for Kernel isolate |
| 915 // to finish initialization. | 914 // to finish initialization. |
| 916 Dart_Port port = Dart_ServiceWaitForKernelPort(); | 915 Dart_Port port = Dart_ServiceWaitForKernelPort(); |
| 917 if (port == ILLEGAL_PORT) { | 916 if (port == ILLEGAL_PORT) { |
| 918 *error = strdup("Error while initializing Kernel isolate"); | 917 *error = strdup("Error while initializing Kernel isolate"); |
| 919 return NULL; | 918 return NULL; |
| 920 } | 919 } |
| 921 } | 920 } |
| 922 | 921 |
| 923 if (run_app_snapshot) { | 922 if (run_app_snapshot) { |
| (...skipping 1061 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1985 Platform::Exit(Process::GlobalExitCode()); | 1984 Platform::Exit(Process::GlobalExitCode()); |
| 1986 } | 1985 } |
| 1987 | 1986 |
| 1988 } // namespace bin | 1987 } // namespace bin |
| 1989 } // namespace dart | 1988 } // namespace dart |
| 1990 | 1989 |
| 1991 int main(int argc, char** argv) { | 1990 int main(int argc, char** argv) { |
| 1992 dart::bin::main(argc, argv); | 1991 dart::bin::main(argc, argv); |
| 1993 UNREACHABLE(); | 1992 UNREACHABLE(); |
| 1994 } | 1993 } |
| OLD | NEW |