5#ifndef INCLUDE_V8_MAYBE_H_
6#define INCLUDE_V8_MAYBE_H_
17namespace api_internal {
87 return (
IsJust() == other.IsJust()) &&
107 template <
class U, std::enable_if_t<!std::is_lvalue_reference_v<U>>*>
124template <
class T, std::enable_if_t<!std::is_lvalue_reference_v<T>>* =
nullptr>
137 return IsJust() == other.IsJust();
V8_INLINE bool operator==(const Maybe &other) const
V8_INLINE bool IsJust() const
V8_INLINE bool operator!=(const Maybe &other) const
V8_INLINE bool IsNothing() const
friend Maybe< U > Nothing()
V8_INLINE bool operator!=(const Maybe &other) const
V8_INLINE T FromMaybe(const T &default_value) const
V8_WARN_UNUSED_RESULT V8_INLINE bool To(T *out) const
friend Maybe< U > Just(U &&u)
V8_INLINE bool IsJust() const
V8_INLINE void Check() const
V8_INLINE T FromJust() const &
V8_INLINE T FromJust() &&
V8_INLINE T ToChecked() const
friend Maybe< U > Just(const U &u)
V8_INLINE bool operator==(const Maybe &other) const
V8_INLINE bool IsNothing() const
Maybe< T > Just(const T &t)
#define V8_LIKELY(condition)
#define V8_WARN_UNUSED_RESULT
#define V8_UNLIKELY(condition)