1
0
mirror of https://github.com/godotengine/godot.git synced 2025-11-28 16:07:14 +00:00

Mono: Implement stack info for errors and exceptions

This commit is contained in:
Ignacio Etcheverry
2018-01-09 17:19:03 +01:00
parent 52165fa12d
commit 5be356b72f
15 changed files with 311 additions and 74 deletions

View File

@@ -349,7 +349,9 @@ public:
csi.resize(_debug_call_stack_pos);
for (int i = 0; i < _debug_call_stack_pos; i++) {
csi[_debug_call_stack_pos - i - 1].line = _call_stack[i].line ? *_call_stack[i].line : 0;
csi[_debug_call_stack_pos - i - 1].script = Ref<GDScript>(_call_stack[i].function->get_script());
if (_call_stack[i].function)
csi[_debug_call_stack_pos - i - 1].func = _call_stack[i].function->get_name();
csi[_debug_call_stack_pos - i - 1].file = _call_stack[i].function->get_script()->get_path();
}
return csi;
}