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

Side by Side Diff: src/parser.h

Issue 549207: Added validating JSON parser mode to parser. (Closed)
Patch Set: Created 10 years, 10 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
« no previous file with comments | « src/json-delay.js ('k') | src/parser.cc » ('j') | src/parser.cc » ('J')
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2006-2008 the V8 project authors. All rights reserved. 1 // Copyright 2006-2008 the V8 project authors. All rights reserved.
2 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 115 matching lines...) Expand 10 before | Expand all | Expand 10 after
126 int last_entry_; 126 int last_entry_;
127 }; 127 };
128 128
129 129
130 // The parser: Takes a script and and context information, and builds a 130 // The parser: Takes a script and and context information, and builds a
131 // FunctionLiteral AST node. Returns NULL and deallocates any allocated 131 // FunctionLiteral AST node. Returns NULL and deallocates any allocated
132 // AST nodes if parsing failed. 132 // AST nodes if parsing failed.
133 FunctionLiteral* MakeAST(bool compile_in_global_context, 133 FunctionLiteral* MakeAST(bool compile_in_global_context,
134 Handle<Script> script, 134 Handle<Script> script,
135 v8::Extension* extension, 135 v8::Extension* extension,
136 ScriptDataImpl* pre_data); 136 ScriptDataImpl* pre_data,
137 bool is_json = false);
Mads Ager (chromium) 2010/02/01 08:42:19 Can we use the validation state enum here instead
137 138
138 139
139 ScriptDataImpl* PreParse(Handle<String> source, 140 ScriptDataImpl* PreParse(Handle<String> source,
140 unibrow::CharacterStream* stream, 141 unibrow::CharacterStream* stream,
141 v8::Extension* extension); 142 v8::Extension* extension);
142 143
143 144
144 bool ParseRegExp(FlatStringReader* input, 145 bool ParseRegExp(FlatStringReader* input,
145 bool multiline, 146 bool multiline,
146 RegExpCompileData* result); 147 RegExpCompileData* result);
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
186 static const int kTypeSlot = 0; 187 static const int kTypeSlot = 0;
187 static const int kElementsSlot = 1; 188 static const int kElementsSlot = 1;
188 189
189 DISALLOW_IMPLICIT_CONSTRUCTORS(CompileTimeValue); 190 DISALLOW_IMPLICIT_CONSTRUCTORS(CompileTimeValue);
190 }; 191 };
191 192
192 193
193 } } // namespace v8::internal 194 } } // namespace v8::internal
194 195
195 #endif // V8_PARSER_H_ 196 #endif // V8_PARSER_H_
OLDNEW
« no previous file with comments | « src/json-delay.js ('k') | src/parser.cc » ('j') | src/parser.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698