| 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 <stdio.h> | 6 #include <stdio.h> |
| 7 #include <string.h> | 7 #include <string.h> |
| 8 | 8 |
| 9 #include "include/dart_api.h" | 9 #include "include/dart_api.h" |
| 10 | 10 |
| (...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 55 V(File_Delete, 1) \ | 55 V(File_Delete, 1) \ |
| 56 V(File_DeleteLink, 1) \ | 56 V(File_DeleteLink, 1) \ |
| 57 V(File_Rename, 2) \ | 57 V(File_Rename, 2) \ |
| 58 V(File_Copy, 2) \ | 58 V(File_Copy, 2) \ |
| 59 V(File_RenameLink, 2) \ | 59 V(File_RenameLink, 2) \ |
| 60 V(File_ResolveSymbolicLinks, 1) \ | 60 V(File_ResolveSymbolicLinks, 1) \ |
| 61 V(File_OpenStdio, 1) \ | 61 V(File_OpenStdio, 1) \ |
| 62 V(File_GetStdioHandleType, 1) \ | 62 V(File_GetStdioHandleType, 1) \ |
| 63 V(File_GetType, 2) \ | 63 V(File_GetType, 2) \ |
| 64 V(File_AreIdentical, 2) \ | 64 V(File_AreIdentical, 2) \ |
| 65 V(Logger_PrintString, 1) | 65 V(Logger_PrintString, 1) \ |
| 66 V(Builtin_LoadScript, 2) \ |
| 67 V(Builtin_LoadLibrarySource, 4) \ |
| 68 V(Builtin_AsyncLoadError, 2) \ |
| 69 |
| 66 | 70 |
| 67 BUILTIN_NATIVE_LIST(DECLARE_FUNCTION); | 71 BUILTIN_NATIVE_LIST(DECLARE_FUNCTION); |
| 68 | 72 |
| 69 static struct NativeEntries { | 73 static struct NativeEntries { |
| 70 const char* name_; | 74 const char* name_; |
| 71 Dart_NativeFunction function_; | 75 Dart_NativeFunction function_; |
| 72 int argument_count_; | 76 int argument_count_; |
| 73 } BuiltinEntries[] = { | 77 } BuiltinEntries[] = { |
| 74 BUILTIN_NATIVE_LIST(REGISTER_FUNCTION) | 78 BUILTIN_NATIVE_LIST(REGISTER_FUNCTION) |
| 75 }; | 79 }; |
| (...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 127 } else { | 131 } else { |
| 128 // Uses fwrite to support printing NUL bytes. | 132 // Uses fwrite to support printing NUL bytes. |
| 129 fwrite(chars, 1, length, stdout); | 133 fwrite(chars, 1, length, stdout); |
| 130 fputs("\n", stdout); | 134 fputs("\n", stdout); |
| 131 } | 135 } |
| 132 fflush(stdout); | 136 fflush(stdout); |
| 133 } | 137 } |
| 134 | 138 |
| 135 } // namespace bin | 139 } // namespace bin |
| 136 } // namespace dart | 140 } // namespace dart |
| OLD | NEW |