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

Unified Diff: runtime/vm/object.h

Issue 2416963009: Minor cleanup: use handle when setting instructions in code object. (Closed)
Patch Set: Created 4 years, 2 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 | « no previous file | runtime/vm/object.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/object.h
diff --git a/runtime/vm/object.h b/runtime/vm/object.h
index 82f3ef7b990bdc2b6ef496bd74688da7026d3bf0..6a00a5a6bd1bfc9c47ae58d73ef62966171c1309 100644
--- a/runtime/vm/object.h
+++ b/runtime/vm/object.h
@@ -4945,7 +4945,7 @@ class Code : public Object {
if (!IsDisabled()) return;
ASSERT(Thread::Current()->IsMutatorThread());
ASSERT(instructions() != active_instructions());
- SetActiveInstructions(instructions());
+ SetActiveInstructions(Instructions::Handle(instructions()));
}
bool IsDisabled() const {
@@ -5001,11 +5001,11 @@ class Code : public Object {
#endif
}
- void SetActiveInstructions(RawInstructions* instructions) const;
+ void SetActiveInstructions(const Instructions& instructions) const;
- void set_instructions(RawInstructions* instructions) const {
+ void set_instructions(const Instructions& instructions) const {
ASSERT(Thread::Current()->IsMutatorThread() || !is_alive());
- StorePointer(&raw_ptr()->instructions_, instructions);
+ StorePointer(&raw_ptr()->instructions_, instructions.raw());
}
void set_pointer_offsets_length(intptr_t value) {
« no previous file with comments | « no previous file | runtime/vm/object.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698