File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -138,6 +138,16 @@ std::string Status::ToStringWithoutContextLines() const {
138138 return message;
139139}
140140
141+ const std::string& Status::message () const {
142+ static const std::string no_message = " " ;
143+ return ok () ? no_message : state_->msg ;
144+ }
145+
146+ const std::shared_ptr<StatusDetail>& Status::detail () const {
147+ static std::shared_ptr<StatusDetail> no_detail = NULLPTR;
148+ return state_ ? state_->detail : no_detail;
149+ }
150+
141151void Status::Abort () const { Abort (std::string ()); }
142152
143153void Status::Abort (const std::string& message) const {
Original file line number Diff line number Diff line change @@ -329,16 +329,10 @@ class ARROW_EXPORT [[nodiscard]] Status : public util::EqualityComparable<Status
329329 constexpr StatusCode code () const { return ok () ? StatusCode::OK : state_->code ; }
330330
331331 // / \brief Return the specific error message attached to this status.
332- const std::string& message () const {
333- static const std::string no_message = " " ;
334- return ok () ? no_message : state_->msg ;
335- }
332+ const std::string& message () const ;
336333
337334 // / \brief Return the status detail attached to this message.
338- const std::shared_ptr<StatusDetail>& detail () const {
339- static std::shared_ptr<StatusDetail> no_detail = NULLPTR;
340- return state_ ? state_->detail : no_detail;
341- }
335+ const std::shared_ptr<StatusDetail>& detail () const ;
342336
343337 // / \brief Return a new Status copying the existing status, but
344338 // / updating with the existing detail.
You can’t perform that action at this time.
0 commit comments