[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Question on Backtrace


Le 20/07/2025 à 21:31, gbWilly a écrit :
Hi all,

I got a question on Backtrace I don't seem to be able to answer.
Below a screenshot of a piece of code. that shows a debug of last Backtrace record in the array.
It is ? and someone asked why the ? returned as it makes no sense.

image.png

The actual backtrace can be seen in console output as being
For index 0: Main.DivideByZero.19
For index 1: Main.Main.6
For index 2: ?   <-- what is this all about?

I presume it represents gb or root or something the likes.

Anyone any idea?

gbWilly


It's the interpreter that internally creates a "void" stack entry when a function is called outside of the bytecode interpretation function (for example from the event loop, or from the NEW operator calling the constructor functions,...).

It allows to know when the bytecode interpretation function must be ended when unrolling the stack frame after an error has been raised.

I didn't find a way to get rid of it for years.

Regards,

--
Benoît Minisini.


Follow-Ups:
Re: Question on BacktracegbWilly <gbWilly@xxxxxxxxxxxxxx>
References:
Question on BacktracegbWilly <gbWilly@xxxxxxxxxxxxxx>