summaryrefslogtreecommitdiffstats
path: root/src/parser.h
diff options
context:
space:
mode:
authorSteve Block <steveblock@google.com>2011-05-12 15:51:54 +0100
committerSteve Block <steveblock@google.com>2011-05-12 16:12:25 +0100
commit9fac840a46e8b7e26894f4792ba26dde14c56b04 (patch)
tree0b8b71befb5175abac552daa0d084fc51c1090b8 /src/parser.h
parentb0fe1620dcb4135ac3ab2d66ff93072373911299 (diff)
downloadandroid_external_v8-9fac840a46e8b7e26894f4792ba26dde14c56b04.tar.gz
android_external_v8-9fac840a46e8b7e26894f4792ba26dde14c56b04.tar.bz2
android_external_v8-9fac840a46e8b7e26894f4792ba26dde14c56b04.zip
Update V8 to r6190 as required by WebKit r75315
Change-Id: I0b2f598e4d8748df417ad350fc47a1c465ad1fef
Diffstat (limited to 'src/parser.h')
-rw-r--r--src/parser.h26
1 files changed, 22 insertions, 4 deletions
diff --git a/src/parser.h b/src/parser.h
index 70d0e18f..8623f384 100644
--- a/src/parser.h
+++ b/src/parser.h
@@ -578,6 +578,26 @@ class Parser {
bool Check(Token::Value token);
void ExpectSemicolon(bool* ok);
+ Handle<String> LiteralString(PretenureFlag tenured) {
+ if (scanner().is_literal_ascii()) {
+ return Factory::NewStringFromAscii(scanner().literal_ascii_string(),
+ tenured);
+ } else {
+ return Factory::NewStringFromTwoByte(scanner().literal_uc16_string(),
+ tenured);
+ }
+ }
+
+ Handle<String> NextLiteralString(PretenureFlag tenured) {
+ if (scanner().is_next_literal_ascii()) {
+ return Factory::NewStringFromAscii(scanner().next_literal_ascii_string(),
+ tenured);
+ } else {
+ return Factory::NewStringFromTwoByte(scanner().next_literal_uc16_string(),
+ tenured);
+ }
+ }
+
Handle<String> GetSymbol(bool* ok);
// Get odd-ball literals.
@@ -612,11 +632,9 @@ class Parser {
Scope* NewScope(Scope* parent, Scope::Type type, bool inside_with);
- Handle<String> LookupSymbol(int symbol_id,
- Vector<const char> string);
+ Handle<String> LookupSymbol(int symbol_id);
- Handle<String> LookupCachedSymbol(int symbol_id,
- Vector<const char> string);
+ Handle<String> LookupCachedSymbol(int symbol_id);
Expression* NewCall(Expression* expression,
ZoneList<Expression*>* arguments,