BRAINSTORM: Exceptions using delegates, goto: out of a delegate literal?
Russell Lewis
webmaster at villagersonline.com
Tue Jan 22 07:33:48 PST 2008
Craig Black wrote:
> Interesting idea, but you failed to highlight the other things that could be
> done with this besides exceptions. Further, the syntax for exceptions is
> pretty well established, so any modifications to it would require very
> compelling explanations. It's easy to bash someone with a new idea, so
> sorry if it seems like I'm bashing.
Actually, you're the most charitable of the responses. :)
I agree that I have not stated any compelling "other use" for this.
It's because I don't know of one, yet. But my gut says that this falls
in the category of "has many unexpected uses" features. I thought I
would throw it out for others to chew on before I forgot it.
Let's set aside the syntax sugar thing I proposed for a moment and just
look at the goto: proposal. IMHO, having a language-supported longjmp
is certainly an intriguing idea. The only thing I can think of right
now that would make it hard would be that you'd need to clean up finally
blocks and auto variables as you accomplished the goto. Hmm.
More information about the Digitalmars-d
mailing list