Exception class. ********************************************************************/
| 91 | Exception class. |
| 92 | ********************************************************************/ |
| 93 | class ap_error |
| 94 | { |
| 95 | public: |
| 96 | ap_error(){}; |
| 97 | ap_error(const char *s){ msg = s; }; |
| 98 | |
| 99 | std::string msg; |
| 100 | |
| 101 | static void make_assertion(bool bClause) |
| 102 | { if(!bClause) throw ap_error(); }; |
| 103 | static void make_assertion(bool bClause, const char *msg) |
| 104 | { if(!bClause) throw ap_error(msg); }; |
| 105 | private: |
| 106 | }; |
| 107 | |
| 108 | /******************************************************************** |
| 109 | Class defining a complex number with double precision. |