[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: Re: stack level parameter
- From: Alexander Gladysh <agladysh@...>
- Date: Tue, 19 Jan 2010 21:47:54 +0300
> When throwing an error, you want the user to know where in the source
> the error is, not where error is called. Removing the stack index
> parameter will most likely make it useless for
> module/library/framework writers.
Indeed. But absolute stack level delta is actually kind of not
comfortable enough. One has to use different stack levels for
different "system call" nesting levels. Like this:
error("foo", (level or 1) + 1)
foo((level or 1) + 1)
I like the idea with marking call frames as "hidden" instead. This
should reduce the hassle.