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

Unified Diff: src/factory.h

Issue 11759008: Introduce ENABLE_LATIN_1 compile flag (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Fix FilterASCII Created 7 years, 11 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/compiler.cc ('k') | src/factory.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/factory.h
diff --git a/src/factory.h b/src/factory.h
index 54933355eb3c84af4702dba85b437051a11bc3b3..522639dd64669e9ad704d54d4f36195ec61d1bc6 100644
--- a/src/factory.h
+++ b/src/factory.h
@@ -84,7 +84,7 @@ class Factory {
return LookupUtf8Symbol(CStrVector(str));
}
Handle<String> LookupSymbol(Handle<String> str);
- Handle<String> LookupOneByteSymbol(Vector<const char> str);
+ Handle<String> LookupOneByteSymbol(Vector<const uint8_t> str);
Handle<String> LookupOneByteSymbol(Handle<SeqOneByteString>,
int from,
int length);
@@ -113,9 +113,15 @@ class Factory {
// two byte.
//
// ASCII strings are pretenured when used as keys in the SourceCodeCache.
- Handle<String> NewStringFromAscii(
- Vector<const char> str,
+ Handle<String> NewStringFromOneByte(
+ Vector<const uint8_t> str,
PretenureFlag pretenure = NOT_TENURED);
+ // TODO(dcarney): remove this function.
+ inline Handle<String> NewStringFromAscii(
+ Vector<const char> str,
+ PretenureFlag pretenure = NOT_TENURED) {
+ return NewStringFromOneByte(Vector<const uint8_t>::cast(str), pretenure);
+ }
// UTF8 strings are pretenured when used for regexp literal patterns and
// flags in the parser.
« no previous file with comments | « src/compiler.cc ('k') | src/factory.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698