blob: 4d263f1b2fd1cf8755ebf6cbfe2c17e459a85850 [file] [log] [blame]
Phil Nash1091ca82012-08-06 20:16:53 +01001/*
2 * Created by Phil on 5/8/2012.
3 * Copyright 2012 Two Blue Cubes Ltd. All rights reserved.
4 *
5 * Distributed under the Boost Software License, Version 1.0. (See accompanying
6 * file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
7 */
8#ifndef TWOBLUECUBES_CATCH_NOTIMPLEMENTED_EXCEPTION_HPP_INCLUDED
9#define TWOBLUECUBES_CATCH_NOTIMPLEMENTED_EXCEPTION_HPP_INCLUDED
Phil Nash5234b152012-08-06 08:33:15 +010010
Phil Nash1091ca82012-08-06 20:16:53 +010011#include "catch_notimplemented_exception.h"
12#include <ostream>
Phil Nash5234b152012-08-06 08:33:15 +010013
Phil Nash1091ca82012-08-06 20:16:53 +010014namespace Catch {
Phil Nash5234b152012-08-06 08:33:15 +010015
Phil Nash2a9d8d92013-04-23 18:58:56 +010016 NotImplementedException::NotImplementedException( SourceLineInfo const& lineInfo )
Phil Nash1091ca82012-08-06 20:16:53 +010017 : m_lineInfo( lineInfo ) {
18 std::ostringstream oss;
Phil Nash42aef1d2013-01-13 21:51:44 +000019 oss << lineInfo << ": function ";
Phil Nash1091ca82012-08-06 20:16:53 +010020 oss << "not implemented";
21 m_what = oss.str();
22 }
Phil Nash5234b152012-08-06 08:33:15 +010023
gnzlbgce659852014-03-20 12:48:19 +010024 const char* NotImplementedException::what() const CATCH_NOEXCEPT {
Phil Nash1091ca82012-08-06 20:16:53 +010025 return m_what.c_str();
26 }
Phil Nashf3d1f082013-07-03 19:14:59 +010027
Phil Nash1091ca82012-08-06 20:16:53 +010028} // end namespace Catch
29
Matt Wozniskif29c8982012-09-17 01:42:29 -040030#endif // TWOBLUECUBES_CATCH_NOTIMPLEMENTED_EXCEPTION_HPP_INCLUDED