diff options
author | Tuowen Zhao <ztuowen@gmail.com> | 2016-09-26 15:18:38 -0600 |
---|---|---|
committer | Tuowen Zhao <ztuowen@gmail.com> | 2016-09-26 15:18:38 -0600 |
commit | 15e8ff480e7a75f4dce8c8d41da157cf51bd3cb8 (patch) | |
tree | 9bbdc313f0614689e9276ed615dd780f1faccfd6 /include | |
parent | f4474891acec5918f94bc126fed8eb9bb2792912 (diff) | |
download | chill-15e8ff480e7a75f4dce8c8d41da157cf51bd3cb8.tar.gz chill-15e8ff480e7a75f4dce8c8d41da157cf51bd3cb8.tar.bz2 chill-15e8ff480e7a75f4dce8c8d41da157cf51bd3cb8.zip |
namespaced error
Diffstat (limited to 'include')
-rw-r--r-- | include/chill_error.hh | 35 |
1 files changed, 19 insertions, 16 deletions
diff --git a/include/chill_error.hh b/include/chill_error.hh index 7321e75..20a8362 100644 --- a/include/chill_error.hh +++ b/include/chill_error.hh @@ -6,23 +6,26 @@ * \brief CHiLL runtime exceptions */ -//! for loop transformation problem -struct loop_error : public std::runtime_error { - loop_error(const std::string &msg) : std::runtime_error(msg) {} -}; +namespace chill { + namespace error { + //! for loop transformation problem + struct loop : public std::runtime_error { + loop(const std::string &msg) : std::runtime_error(msg) {} + }; -//! for generic compiler intermediate code handling problem -struct ir_error : public std::runtime_error { - ir_error(const std::string &msg) : std::runtime_error(msg) {} -}; + //! for generic compiler intermediate code handling problem + struct ir : public std::runtime_error { + ir(const std::string &msg) : std::runtime_error(msg) {} + }; -//! for specific for expression to preburger math translation problem -struct ir_exp_error : public ir_error { - ir_exp_error(const std::string &msg) : ir_error(msg) {} -}; - -struct omega_error : public std::runtime_error { - omega_error(const std::string &msg) : std::runtime_error(msg) {} -}; + //! for specific for expression to preburger math translation problem + struct ir_exp : public ir { + ir_exp(const std::string &msg) : ir(msg) {} + }; + struct omega : public std::runtime_error { + omega(const std::string &msg) : std::runtime_error(msg) {} + }; + } +} #endif |