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

Unified Diff: runtime/vm/kernel_binary_flowgraph.h

Issue 2995423002: Allow the VM to read Kernel files with external libraries (Closed)
Patch Set: Created 3 years, 4 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 | « runtime/vm/kernel_binary.h ('k') | runtime/vm/kernel_binary_flowgraph.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/kernel_binary_flowgraph.h
diff --git a/runtime/vm/kernel_binary_flowgraph.h b/runtime/vm/kernel_binary_flowgraph.h
index 28ac4b88303153440927dfd81ec9b74a10d6fde6..87caf192a3c382b00ceb9f0b77174a59931dda45 100644
--- a/runtime/vm/kernel_binary_flowgraph.h
+++ b/runtime/vm/kernel_binary_flowgraph.h
@@ -119,7 +119,7 @@ class VariableDeclarationHelper {
TokenPosition position_;
TokenPosition equals_position_;
- word flags_;
+ uint8_t flags_;
StringIndex name_index_;
private:
@@ -190,7 +190,7 @@ class FieldHelper {
NameIndex canonical_name_;
TokenPosition position_;
TokenPosition end_position_;
- word flags_;
+ uint8_t flags_;
intptr_t source_uri_index_;
intptr_t annotation_count_;
@@ -265,7 +265,7 @@ class ProcedureHelper {
TokenPosition position_;
TokenPosition end_position_;
Kind kind_;
- word flags_;
+ uint8_t flags_;
intptr_t source_uri_index_;
intptr_t annotation_count_;
@@ -322,7 +322,7 @@ class ConstructorHelper {
NameIndex canonical_name_;
TokenPosition position_;
TokenPosition end_position_;
- word flags_;
+ uint8_t flags_;
intptr_t annotation_count_;
private:
@@ -410,6 +410,10 @@ class LibraryHelper {
kEnd,
};
+ enum Flag {
+ kExternal = 1,
+ };
+
explicit LibraryHelper(StreamingFlowGraphBuilder* builder) {
builder_ = builder;
next_read_ = kFlags;
@@ -424,6 +428,9 @@ class LibraryHelper {
void SetNext(Field field) { next_read_ = field; }
void SetJustRead(Field field) { next_read_ = field + 1; }
+ bool IsExternal() const { return (flags_ & kExternal) != 0; }
+
+ uint8_t flags_;
NameIndex canonical_name_;
StringIndex name_index_;
intptr_t source_uri_index_;
@@ -837,7 +844,7 @@ class StreamingFlowGraphBuilder {
void record_yield_position(TokenPosition position);
Tag ReadTag(uint8_t* payload = NULL);
Tag PeekTag(uint8_t* payload = NULL);
- word ReadFlags();
+ uint8_t ReadFlags() { return reader_->ReadFlags(); }
void loop_depth_inc();
void loop_depth_dec();
« no previous file with comments | « runtime/vm/kernel_binary.h ('k') | runtime/vm/kernel_binary_flowgraph.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698