尝试新增命名空间的命名, 用于具有名称的块或是函数

This commit is contained in:
2025-10-15 16:50:10 +08:00
parent 4f358c9664
commit b8a87bae4c
4 changed files with 130 additions and 75 deletions

View File

@@ -3,9 +3,16 @@
namespace Convention.RScript
{
[Serializable]
public class RScriptException : Exception
public class RScriptRuntimeException : Exception
{
public RScriptException(string message, int runtimePointer) : base($"when running {runtimePointer}, {message}") { }
public RScriptException(string message, int runtimePointer, Exception inner) : base($"when running {runtimePointer}, {message}", inner) { }
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 : Exception
{
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) { }
}
}