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 #ifndef BIN_BUILTIN_H_ | 5 #ifndef BIN_BUILTIN_H_ |
6 #define BIN_BUILTIN_H_ | 6 #define BIN_BUILTIN_H_ |
7 | 7 |
8 #include <stdio.h> | 8 #include <stdio.h> |
9 #include <stdlib.h> | 9 #include <stdlib.h> |
10 | 10 |
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
47 // load it. | 47 // load it. |
48 static Dart_Handle LoadAndCheckLibrary(BuiltinLibraryId id); | 48 static Dart_Handle LoadAndCheckLibrary(BuiltinLibraryId id); |
49 | 49 |
50 private: | 50 private: |
51 // Map specified URI to an actual file name from 'source_paths' and read | 51 // Map specified URI to an actual file name from 'source_paths' and read |
52 // the file. | 52 // the file. |
53 static Dart_Handle GetSource(const char** source_paths, const char* uri); | 53 static Dart_Handle GetSource(const char** source_paths, const char* uri); |
54 | 54 |
55 // Native method support. | 55 // Native method support. |
56 static Dart_NativeFunction NativeLookup(Dart_Handle name, | 56 static Dart_NativeFunction NativeLookup(Dart_Handle name, |
57 int argument_count); | 57 int argument_count, |
| 58 bool* auto_setup_scope); |
58 | 59 |
59 static const char* builtin_source_paths_[]; | 60 static const char* builtin_source_paths_[]; |
60 static const char* io_source_paths_[]; | 61 static const char* io_source_paths_[]; |
61 static const char* io_patch_paths_[]; | 62 static const char* io_patch_paths_[]; |
62 | 63 |
63 typedef struct { | 64 typedef struct { |
64 const char* url_; | 65 const char* url_; |
65 const char** source_paths_; | 66 const char** source_paths_; |
66 const char* patch_url_; | 67 const char* patch_url_; |
67 const char** patch_paths_; | 68 const char** patch_paths_; |
68 bool has_natives_; | 69 bool has_natives_; |
69 } builtin_lib_props; | 70 } builtin_lib_props; |
70 static builtin_lib_props builtin_libraries_[]; | 71 static builtin_lib_props builtin_libraries_[]; |
71 | 72 |
72 DISALLOW_ALLOCATION(); | 73 DISALLOW_ALLOCATION(); |
73 DISALLOW_IMPLICIT_CONSTRUCTORS(Builtin); | 74 DISALLOW_IMPLICIT_CONSTRUCTORS(Builtin); |
74 }; | 75 }; |
75 | 76 |
76 } // namespace bin | 77 } // namespace bin |
77 } // namespace dart | 78 } // namespace dart |
78 | 79 |
79 #endif // BIN_BUILTIN_H_ | 80 #endif // BIN_BUILTIN_H_ |
OLD | NEW |