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

Unified Diff: src/preparse-data.h

Issue 198583003: Convert scanner buffers to use standard character types. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 9 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/parser.cc ('k') | src/scanner.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/preparse-data.h
diff --git a/src/preparse-data.h b/src/preparse-data.h
index 2bc42bd928d6bb7c135480f9c6ca76f9ce75a82c..07b9d4ca3236323a3003ad50a70417d7be83e8e4 100644
--- a/src/preparse-data.h
+++ b/src/preparse-data.h
@@ -52,8 +52,8 @@ class ParserRecorder {
StrictMode strict_mode) = 0;
// Logs a symbol creation of a literal or identifier.
- virtual void LogAsciiSymbol(int start, Vector<const char> literal) { }
- virtual void LogUtf16Symbol(int start, Vector<const uc16> literal) { }
+ virtual void LogOneByteSymbol(int start, Vector<const uint8_t> literal) = 0;
+ virtual void LogTwoByteSymbol(int start, Vector<const uint16_t> literal) = 0;
// Logs an error message and marks the log as containing an error.
// Further logging will be ignored, and ExtractData will return a vector
@@ -148,8 +148,8 @@ class FunctionLoggingParserRecorder : public ParserRecorder {
class PartialParserRecorder : public FunctionLoggingParserRecorder {
public:
PartialParserRecorder() : FunctionLoggingParserRecorder() { }
- virtual void LogAsciiSymbol(int start, Vector<const char> literal) { }
- virtual void LogUtf16Symbol(int start, Vector<const uc16> literal) { }
+ virtual void LogOneByteSymbol(int start, Vector<const uint8_t> literal) { }
+ virtual void LogTwoByteSymbol(int start, Vector<const uint16_t> literal) { }
virtual ~PartialParserRecorder() { }
virtual Vector<unsigned> ExtractData();
virtual int symbol_position() { return 0; }
@@ -165,13 +165,13 @@ class CompleteParserRecorder: public FunctionLoggingParserRecorder {
CompleteParserRecorder();
virtual ~CompleteParserRecorder() { }
- virtual void LogAsciiSymbol(int start, Vector<const char> literal) {
+ virtual void LogOneByteSymbol(int start, Vector<const uint8_t> literal) {
if (!is_recording_) return;
int hash = vector_hash(literal);
- LogSymbol(start, hash, true, Vector<const byte>::cast(literal));
+ LogSymbol(start, hash, true, literal);
}
- virtual void LogUtf16Symbol(int start, Vector<const uc16> literal) {
+ virtual void LogTwoByteSymbol(int start, Vector<const uint16_t> literal) {
if (!is_recording_) return;
int hash = vector_hash(literal);
LogSymbol(start, hash, false, Vector<const byte>::cast(literal));
« no previous file with comments | « src/parser.cc ('k') | src/scanner.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698