aboutsummaryrefslogtreecommitdiff
path: root/asm
diff options
context:
space:
mode:
authorAryadev Chavali <aryadev@aryadevchavali.com>2024-04-15 16:33:02 +0630
committerAryadev Chavali <aryadev@aryadevchavali.com>2024-04-15 16:33:02 +0630
commit4a7341e26c9c2bca261520886b10f5c8246f59ef (patch)
treef6a893ab53c440cfa2942e7ea649c85ec7a5e543 /asm
parentb83bdd0d45223b789ec99bdc16d42fb646fdb8e2 (diff)
downloadovm-4a7341e26c9c2bca261520886b10f5c8246f59ef.tar.gz
ovm-4a7341e26c9c2bca261520886b10f5c8246f59ef.tar.bz2
ovm-4a7341e26c9c2bca261520886b10f5c8246f59ef.zip
Propagate changes to lerr_t into preprocesser
Diffstat (limited to 'asm')
-rw-r--r--asm/preprocesser.cpp10
1 files changed, 4 insertions, 6 deletions
diff --git a/asm/preprocesser.cpp b/asm/preprocesser.cpp
index c0cf9e2..e6d40b6 100644
--- a/asm/preprocesser.cpp
+++ b/asm/preprocesser.cpp
@@ -81,7 +81,7 @@ preprocess_use_blocks(const vector<token_t *> &tokens)
std::vector<token_t *> ftokens;
lerr_t lerr = tokenise_buffer(source.value(), ftokens);
- if (lerr != lerr_t::OK)
+ if (lerr.type != lerr_type_t::OK)
{
VCLEAR(new_tokens);
return ERR(pp_err_t(pp_err_type_t::FILE_PARSE_ERROR, name, lerr));
@@ -196,19 +196,17 @@ std::ostream &operator<<(std::ostream &os, pp_err_t &err)
return os << "FILE_NONEXISTENT";
case FILE_PARSE_ERROR:
return os << "FILE_PARSE_ERROR -> \n\t[" << err.reference->content
- << "]: " << lerr_as_cstr(err.lerr);
+ << "]: " << err.lerr;
case UNKNOWN_NAME:
return os << "UNKNOWN_NAME";
}
return os;
}
-pp_err_t::pp_err_t()
- : reference{nullptr}, type{pp_err_type_t::OK}, lerr{lerr_t::OK}
+pp_err_t::pp_err_t() : reference{nullptr}, type{pp_err_type_t::OK}, lerr{}
{}
-pp_err_t::pp_err_t(pp_err_type_t e)
- : reference{nullptr}, type{e}, lerr{lerr_t::OK}
+pp_err_t::pp_err_t(pp_err_type_t e) : reference{nullptr}, type{e}, lerr{}
{}
pp_err_t::pp_err_t(pp_err_type_t err, const token_t *ref)