On Jun 30, 2009, at 11:54 PM, Adam Heath wrote:

Adrian Crum wrote:
Hmm... let's say the simple method operations all kept line numbers in them. The exec method could catch all Exceptions, wrap the original Exception with a MiniLangException - which would also accept the method name and line number - and then throw the MiniLangException. You could still get a stack trace from that, right?

That would mean 2 ints or longs per object.  Not to mention that each
node also has 2 Integers.

I think we should maybe have a combination of both.  Seeing these
things in the stack trace is extremely useful.  You can see the path
the call stack has taken, in addition to the final exception having
embedded position information.

This is a really cool extension and I think would be well worth the few (8 or 16 or whatever) extra bytes per object. Overall I don't think that would be too much memory.

So yeah, I'm all for having it in and on by default...

-David

Reply via email to