File tree 1 file changed +3
-3
lines changed
1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -105,14 +105,14 @@ struct Nullable : protected std::optional<T>
105
105
// The only fabric-scoped objects in the spec are commands, events and structs inside lists, and none of those can be nullable.
106
106
static constexpr bool kIsFabricScoped = false ;
107
107
108
- bool operator ==(const T & other) const { return std::optional<T>:: has_value () && (** this == other) ; }
109
- bool operator !=(const T & other) const { return !(*this == other); }
108
+ inline bool operator ==(const T & other) const { return static_cast < const std::optional<T> &>(* this ) == other; }
109
+ inline bool operator !=(const T & other) const { return !(*this == other); }
110
110
111
111
inline bool operator ==(const Nullable<T> & other) const
112
112
{
113
113
return static_cast <const std::optional<T> &>(*this ) == static_cast <const std::optional<T> &>(other);
114
114
}
115
- bool operator !=(const Nullable<T> & other) const { return !(*this == other); }
115
+ inline bool operator !=(const Nullable<T> & other) const { return !(*this == other); }
116
116
};
117
117
118
118
template <class T >
You can’t perform that action at this time.
0 commit comments