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

Side by Side Diff: src/parser.h

Issue 373713006: Introduce code serializer/deserializer. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: addressed comments and rebased Created 6 years, 5 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 | « src/mksnapshot.cc ('k') | src/parser.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 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef V8_PARSER_H_ 5 #ifndef V8_PARSER_H_
6 #define V8_PARSER_H_ 6 #define V8_PARSER_H_
7 7
8 #include "src/allocation.h" 8 #include "src/allocation.h"
9 #include "src/ast.h" 9 #include "src/ast.h"
10 #include "src/compiler.h" // For CachedDataMode 10 #include "src/compiler.h" // For CachedDataMode
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after
65 : store_(store), 65 : store_(store),
66 owns_store_(true) { } 66 owns_store_(true) { }
67 67
68 ScriptData(Vector<unsigned> store, bool owns_store) 68 ScriptData(Vector<unsigned> store, bool owns_store)
69 : store_(store), 69 : store_(store),
70 owns_store_(owns_store) { } 70 owns_store_(owns_store) { }
71 71
72 // The created ScriptData won't take ownership of the data. If the alignment 72 // The created ScriptData won't take ownership of the data. If the alignment
73 // is not correct, this will copy the data (and the created ScriptData will 73 // is not correct, this will copy the data (and the created ScriptData will
74 // take ownership of the copy). 74 // take ownership of the copy).
75 static ScriptData* New(const char* data, int length); 75 static ScriptData* New(const char* data, int length, bool owns_store = false);
76 76
77 virtual ~ScriptData(); 77 virtual ~ScriptData();
78 virtual int Length(); 78 virtual int Length();
79 virtual const char* Data(); 79 virtual const char* Data();
80 virtual bool HasError(); 80 virtual bool HasError();
81 81
82 void Initialize(); 82 void Initialize();
83 void ReadNextSymbolPosition(); 83 void ReadNextSymbolPosition();
84 84
85 FunctionEntry GetFunctionEntry(int start); 85 FunctionEntry GetFunctionEntry(int start);
(...skipping 765 matching lines...) Expand 10 before | Expand all | Expand 10 after
851 private: 851 private:
852 static const int kLiteralTypeSlot = 0; 852 static const int kLiteralTypeSlot = 0;
853 static const int kElementsSlot = 1; 853 static const int kElementsSlot = 1;
854 854
855 DISALLOW_IMPLICIT_CONSTRUCTORS(CompileTimeValue); 855 DISALLOW_IMPLICIT_CONSTRUCTORS(CompileTimeValue);
856 }; 856 };
857 857
858 } } // namespace v8::internal 858 } } // namespace v8::internal
859 859
860 #endif // V8_PARSER_H_ 860 #endif // V8_PARSER_H_
OLDNEW
« no previous file with comments | « src/mksnapshot.cc ('k') | src/parser.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698