@@ -188,7 +188,7 @@ namespace etl
188188
189189 // *******************************************
190190 // / Get the error.
191- // *******************************************
191+ // *******************************************
192192 ETL_CONSTEXPR14 TError&& error() const && ETL_NOEXCEPT
193193 {
194194 return etl::move (error_value);
@@ -500,7 +500,7 @@ namespace etl
500500 // *******************************************
501501 // / Get the value.
502502 // *******************************************
503- value_type& value () const
503+ const value_type& value () const
504504 {
505505 return etl::get<Value_Type>(storage);
506506 }
@@ -660,7 +660,7 @@ namespace etl
660660 // *******************************************
661661 // /
662662 // *******************************************
663- error_type& error () const
663+ const error_type& error () const
664664 {
665665 return etl::get<Error_Type>(storage);
666666 }
@@ -932,7 +932,7 @@ namespace etl
932932 // / Returns the error
933933 // / Undefined behaviour if an error has not been set.
934934 // *******************************************
935- error_type& error () const
935+ const error_type& error () const
936936 {
937937 return etl::get<Error_Type>(storage);
938938 }
@@ -1107,4 +1107,3 @@ void swap(etl::unexpected<TError>& lhs, etl::unexpected<TError>& rhs)
11071107}
11081108
11091109#endif
1110-
0 commit comments