aboutsummaryrefslogtreecommitdiff
path: root/src/core/Error.cpp
diff options
context:
space:
mode:
authorGeorgios Pinitas <georgios.pinitas@arm.com>2017-12-06 11:53:03 +0000
committerAnthony Barbier <anthony.barbier@arm.com>2018-11-02 16:42:17 +0000
commit631c41a4e3645a948b0f597caa77e8fa91ca0efc (patch)
tree164fd113818b8e890fc16bad97240056cb71e747 /src/core/Error.cpp
parent57f249b08fd65af761d5c8bfe62de117d67a14c7 (diff)
downloadComputeLibrary-631c41a4e3645a948b0f597caa77e8fa91ca0efc.tar.gz
COMPMID-556: Rename Error to Status and inverse logic
Change-Id: Ib57d4f7177cc6179302bda7ad870acb8bd3825f5 Reviewed-on: https://eu-gerrit-1.euhpc.arm.com/112115 Tested-by: BSG Visual Compute Jenkins server to access repositories on http://mpd-gerrit.cambridge.arm.com <bsgcomp@arm.com> Reviewed-by: Anthony Barbier <anthony.barbier@arm.com>
Diffstat (limited to 'src/core/Error.cpp')
-rw-r--r--src/core/Error.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/core/Error.cpp b/src/core/Error.cpp
index be362bb7cf..b593c27a7f 100644
--- a/src/core/Error.cpp
+++ b/src/core/Error.cpp
@@ -30,16 +30,16 @@
using namespace arm_compute;
-Error arm_compute::create_error_va_list(ErrorCode error_code, const char *function, const char *file, const int line, const char *msg, va_list args)
+Status arm_compute::create_error_va_list(ErrorCode error_code, const char *function, const char *file, const int line, const char *msg, va_list args)
{
char out[512];
int offset = snprintf(out, sizeof(out), "in %s %s:%d: ", function, file, line);
vsnprintf(out + offset, sizeof(out) - offset, msg, args);
- return Error(error_code, std::string(out));
+ return Status(error_code, std::string(out));
}
-Error arm_compute::create_error(ErrorCode error_code, const char *function, const char *file, const int line, const char *msg, ...)
+Status arm_compute::create_error(ErrorCode error_code, const char *function, const char *file, const int line, const char *msg, ...)
{
va_list args;
va_start(args, msg);
@@ -54,9 +54,9 @@ void arm_compute::error(const char *function, const char *file, const int line,
va_start(args, msg);
auto err = create_error_va_list(ErrorCode::RUNTIME_ERROR, function, file, line, msg, args);
va_end(args);
- throw std::runtime_error(err.description());
+ throw std::runtime_error(err.error_description());
}
-void Error::internal_throw_on_error()
+void Status::internal_throw_on_error()
{
- throw std::runtime_error(_description);
+ throw std::runtime_error(_error_description);
}