#include <iostream>
#include <stdexcept>

class my_ex: public std::logic_error {
public:
	my_ex(const char* const what): std::logic_error(what) {}
};

void just_throw_the_message(const char* const msg) {
    throw my_ex(msg);
}

int main() {
	try {
		just_throw_the_message("I feel somewhat exceptional.");
	} catch (const std::exception& e) {
		std::cout << "exception caught: " << e.what() << std::endl;
	}
	return 0;
}