add getter

This commit is contained in:
MoAlyousef
2020-09-11 13:24:56 +03:00
parent 0294b95cfc
commit 76a4367b57
2 changed files with 5 additions and 2 deletions
+3 -1
View File
@@ -6,7 +6,9 @@ namespace cmkr::error {
Status::Status(Code ec) noexcept : ec_(ec) {}
Status::operator int() noexcept { return static_cast<int>(ec_); }
Status::operator int() const noexcept { return static_cast<int>(ec_); }
Status::Code Status::code() const noexcept { return ec_; }
} // namespace cmkr::error