mirror of
https://github.com/TES3MP/openmw-tes3mp.git
synced 2025-01-23 17:23:56 +00:00
20 lines
372 B
C++
20 lines
372 B
C++
|
#ifndef __STR_EXCEPTION_H
|
||
|
#define __STR_EXCEPTION_H
|
||
|
|
||
|
#include <exception>
|
||
|
#include <string>
|
||
|
|
||
|
/// A simple exception that takes and holds a string
|
||
|
class str_exception : public std::exception
|
||
|
{
|
||
|
std::string msg;
|
||
|
|
||
|
public:
|
||
|
|
||
|
str_exception(const std::string &m) : msg(m) {}
|
||
|
~str_exception() throw() {}
|
||
|
const char* what() const throw() { return msg.c_str(); }
|
||
|
};
|
||
|
|
||
|
#endif
|