28 lines
1.0 KiB
C#
28 lines
1.0 KiB
C#
using System;
|
|
|
|
namespace Convention.RScript
|
|
{
|
|
|
|
[Serializable]
|
|
public class RScriptException : Exception
|
|
{
|
|
public RScriptException() { }
|
|
public RScriptException(string message) : base(message) { }
|
|
public RScriptException(string message, Exception inner) : base(message, inner) { }
|
|
}
|
|
|
|
[Serializable]
|
|
public class RScriptRuntimeException : RScriptException
|
|
{
|
|
public RScriptRuntimeException(string message, int runtimePointer) : base($"when running {runtimePointer}, {message}") { }
|
|
public RScriptRuntimeException(string message, int runtimePointer, Exception inner) : base($"when running {runtimePointer}, {message}", inner) { }
|
|
}
|
|
|
|
[Serializable]
|
|
public class RScriptCompileException : RScriptException
|
|
{
|
|
public RScriptCompileException(string message, int line, int chIndex) : base($"when compile on line {line} char {chIndex}, {message}") { }
|
|
public RScriptCompileException(string message, int line, int chIndex, Exception inner) : base($"when compile on line {line} char {chIndex}, {message}", inner) { }
|
|
}
|
|
}
|