From 40ec41b44414c4638b7c0bff1f91c3baa6a030ed Mon Sep 17 00:00:00 2001 From: Valeriy Gorelov Date: Mon, 10 Jun 2024 18:28:51 +0300 Subject: [PATCH] Added Exception.Stack() method. Closes #479 --- runtime.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/runtime.go b/runtime.go index 0139ef10..e7c4a26a 100644 --- a/runtime.go +++ b/runtime.go @@ -411,6 +411,10 @@ func (e *Exception) Unwrap() error { return nil } +func (e *Exception) Stack() []StackFrame { + return e.stack +} + func (r *Runtime) createIterProto(val *Object) objectImpl { o := newBaseObjectObj(val, r.global.ObjectPrototype, classObject)