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

Unified Diff: src/ic/ic-state.h

Issue 919703003: WIP: Implement ES6 Spread-calls (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: AssignmentExpressions are not spreadable, add cctests for parsing Created 5 years, 10 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
Index: src/ic/ic-state.h
diff --git a/src/ic/ic-state.h b/src/ic/ic-state.h
index b5f58ed211a1800ede1b7c6022409cfa04669797..f34b65f857deb6089a2d20cf21baaae950d45491 100644
--- a/src/ic/ic-state.h
+++ b/src/ic/ic-state.h
@@ -28,8 +28,8 @@ class CallICState FINAL BASE_EMBEDDED {
enum CallType { METHOD, FUNCTION };
- CallICState(int argc, CallType call_type)
- : argc_(argc), call_type_(call_type) {}
+ CallICState(int argc, CallType call_type, bool is_spread = false)
+ : argc_(argc), call_type_(call_type), is_spread_(is_spread) {}
ExtraICState GetExtraICState() const;
@@ -39,15 +39,18 @@ class CallICState FINAL BASE_EMBEDDED {
int arg_count() const { return argc_; }
CallType call_type() const { return call_type_; }
+ bool is_spread() const { return is_spread_; }
bool CallAsMethod() const { return call_type_ == METHOD; }
private:
class ArgcBits : public BitField<int, 0, Code::kArgumentsBits> {};
class CallTypeBits : public BitField<CallType, Code::kArgumentsBits, 1> {};
+ class IsSpreadBits : public BitField<bool, CallTypeBits::kNext, 1> {};
const int argc_;
const CallType call_type_;
+ const bool is_spread_;
};

Powered by Google App Engine
This is Rietveld 408576698