Think of it this way: you're asking that when you write
return WHATEVER;
(for various values of WHATEVER) that *sometimes* it's context
dependent, and sometimes it's not. Right now, it always is,
which is more consistent, predictable, and explainable than the
alternative.
Or maybe you're asking for the scalar comma operator to no longer
return its right-hand operand, which would at best be inconsistent
with C.
The distance of the context doesn't matter. If I write
return fx();
and sub fx in turn uses
return fy();
and sub fy in turn uses
return fz();
Then all the way down in fz(), you still inherit the context from
many stack frames above you.
You can argue that context dependency is a bad thing, and that
argument would in fact carry some weight. I doubt it would be
enough to sway Larry, who has some very fine reasons of his own to
have context, but nonetheless, there's certainly something to be
said for it. (Though I haven't seen an RFC yet proposing that
context be eliminated.)
--tom
- Re: The distinction between "do BLOCK while COND&qu... Tom Christiansen
- Re: The distinction between "do BLOCK while COND&qu... Chaim Frenkel
- Re: The distinction between "do BLOCK while COND&qu... Tom Christiansen
- Re: The distinction between "do BLOCK while COND&qu... Chaim Frenkel
- Re: The distinction between "do BLOCK while COND&qu... Tom Christiansen
- Re: The distinction between "do BLOCK while COND&qu... Chaim Frenkel
- Re: The distinction between "do BLOCK while COND&qu... Tom Christiansen
- Re: The distinction between "do BLOCK while COND&qu... Chaim Frenkel
- Re: The distinction between "do BLOCK while COND&qu... Tom Christiansen
- Re: The distinction between "do BLOCK while COND&qu... Chaim Frenkel
- Re: The distinction between "do BLOCK while COND&qu... Tom Christiansen
- Re: The distinction between "do BLOCK while COND&qu... Peter Scott
- Re: The distinction between "do BLOCK while COND&qu... Tom Christiansen
- Re: The distinction between "do BLOCK while COND&qu... Peter Scott
- Re: The distinction between "do BLOCK while COND&qu... Nathan Torkington
- Re: The distinction between "do BLOCK while COND&qu... Tom Christiansen
- Re: The distinction between "do BLOCK while COND&qu... Chaim Frenkel
