Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(599)

Side by Side Diff: bin/builtin.h

Issue 10911135: Simplify the builtin functions and get rid of unused code. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/runtime/
Patch Set: Created 8 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | bin/builtin.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 18 matching lines...) Expand all
29 kUriLibrary, 29 kUriLibrary,
30 kCryptoLibrary, 30 kCryptoLibrary,
31 kIOLibrary, 31 kIOLibrary,
32 kUtfLibrary, 32 kUtfLibrary,
33 kWebLibrary, 33 kWebLibrary,
34 34
35 kInvalidLibrary, 35 kInvalidLibrary,
36 }; 36 };
37 37
38 static Dart_Handle Source(BuiltinLibraryId id); 38 static Dart_Handle Source(BuiltinLibraryId id);
39 static void SetupLibrary(Dart_Handle library, BuiltinLibraryId id); 39 static void SetNativeResolver(BuiltinLibraryId id);
40 static Dart_Handle LoadAndCheckLibrary(BuiltinLibraryId id); 40 static Dart_Handle LoadAndCheckLibrary(BuiltinLibraryId id);
41 static void ImportLibrary(Dart_Handle library, BuiltinLibraryId id);
42 static void PrintString(FILE* out, Dart_Handle object); 41 static void PrintString(FILE* out, Dart_Handle object);
43 static void SetupIOLibrary(Dart_Handle io_lib);
44 42
45 private: 43 private:
46 static Dart_NativeFunction NativeLookup(Dart_Handle name, 44 static Dart_NativeFunction NativeLookup(Dart_Handle name,
47 int argument_count); 45 int argument_count);
48 46
49 static const char builtin_source_[]; 47 static const char builtin_source_[];
50 static const char crypto_source_[]; 48 static const char crypto_source_[];
51 static const char io_source_[]; 49 static const char io_source_[];
52 static const char json_source_[]; 50 static const char json_source_[];
53 static const char uri_source_[]; 51 static const char uri_source_[];
54 static const char utf_source_[]; 52 static const char utf_source_[];
55 static const char web_source_[]; 53 static const char web_source_[];
56 54
57 typedef struct { 55 typedef struct {
58 const char* url_; 56 const char* url_;
59 const char* source_; 57 const char* source_;
60 bool has_natives_; 58 bool has_natives_;
61 } builtin_lib_props; 59 } builtin_lib_props;
62 static builtin_lib_props builtin_libraries_[]; 60 static builtin_lib_props builtin_libraries_[];
63 61
64 DISALLOW_ALLOCATION(); 62 DISALLOW_ALLOCATION();
65 DISALLOW_IMPLICIT_CONSTRUCTORS(Builtin); 63 DISALLOW_IMPLICIT_CONSTRUCTORS(Builtin);
66 }; 64 };
67 65
68 66
69 #endif // BIN_BUILTIN_H_ 67 #endif // BIN_BUILTIN_H_
OLDNEW
« no previous file with comments | « no previous file | bin/builtin.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698