Exception style changes.
This commit is contained in:
parent
f8c1d0204b
commit
8f00c503e2
|
@ -64,7 +64,7 @@ abstract class MarkedYAMLException : YAMLException
|
|||
{
|
||||
// Construct a MarkedYAMLException with specified context and problem.
|
||||
this(string context, Mark contextMark, string problem, Mark problemMark,
|
||||
string file = __FILE__, int line = __LINE__) @safe pure
|
||||
string file = __FILE__, int line = __LINE__) @safe pure nothrow
|
||||
{
|
||||
const msg = context ~ '\n' ~
|
||||
(contextMark != problemMark ? contextMark.toString() ~ '\n' : "") ~
|
||||
|
@ -81,6 +81,8 @@ abstract class MarkedYAMLException : YAMLException
|
|||
}
|
||||
|
||||
// Constructors of YAML exceptions are mostly the same, so we use a mixin.
|
||||
//
|
||||
// See_Also: YAMLException
|
||||
template ExceptionCtors()
|
||||
{
|
||||
public this(string msg, string file = __FILE__, int line = __LINE__)
|
||||
|
@ -91,6 +93,8 @@ template ExceptionCtors()
|
|||
}
|
||||
|
||||
// Constructors of marked YAML exceptions are mostly the same, so we use a mixin.
|
||||
//
|
||||
// See_Also: MarkedYAMLException
|
||||
template MarkedExceptionCtors()
|
||||
{
|
||||
public:
|
||||
|
@ -106,4 +110,9 @@ template MarkedExceptionCtors()
|
|||
{
|
||||
super(problem, problemMark, file, line);
|
||||
}
|
||||
|
||||
this(ref const(MarkedYAMLExceptionData) data) @safe pure nothrow
|
||||
{
|
||||
super(data);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue