Index: src/globals.h |
diff --git a/src/globals.h b/src/globals.h |
index 34ba2e95617542c16db7b9aee15686dbf15e5e60..622af22e7f25a72088f9ec17c17a3bbb6ee6cb17 100644 |
--- a/src/globals.h |
+++ b/src/globals.h |
@@ -1098,6 +1098,20 @@ inline bool IsConstructable(FunctionKind kind, LanguageMode mode) { |
return true; |
} |
+enum class CallableType : unsigned { kJSFunction, kAny }; |
+ |
+inline size_t hash_value(CallableType type) { return bit_cast<unsigned>(type); } |
+ |
+inline std::ostream& operator<<(std::ostream& os, CallableType function_type) { |
+ switch (function_type) { |
+ case CallableType::kJSFunction: |
+ return os << "JSFunction"; |
+ case CallableType::kAny: |
+ return os << "Any"; |
+ } |
+ UNREACHABLE(); |
+ return os; |
+} |
inline uint32_t ObjectHash(Address address) { |
// All objects are at least pointer aligned, so we can remove the trailing |