On Friday, October 05, 2012 00:36:22 Adam D. Ruppe wrote:
> On Thursday, 4 October 2012 at 22:28:24 UTC, David Nadlinger
> 
> wrote:
> > how often have you really encountered big syntactic headaches
> > because of not having something like this available?
> 
> I do somewhat regularly. The if(auto x = y()) { use x } is pretty
> convenient but being limited only to the bool check is kinda weak.

Yeah. It would definitely be useful to be able to do like you do with a for 
loop with an if, but in that case, I'd probably suggest just making it look 
like it looks like with for.

if(auto x = y(); x != 42)
{}

That would be really cool, but I expect that it would be hard to talk Walter 
into it.

- Jonathan M Davis

Reply via email to