On Tuesday, January 03, 2012 11:52:13 Matej Nanut wrote:
Hello everyone,
I would like to know whether
if (symbol in symbols)
return symbols[symbol];
is any less efficient than
auto tmp = symbol in symbols;
if (tmp !is null)
On 01/03/2012 12:07 PM, Jonathan M Davis wrote:
On Tuesday, January 03, 2012 11:52:13 Matej Nanut wrote:
Hello everyone,
I would like to know whether
if (symbol in symbols)
return symbols[symbol];
is any less efficient than
auto tmp = symbol in symbols;
On Tuesday, January 03, 2012 12:13:45 Timon Gehr wrote:
On 01/03/2012 12:07 PM, Jonathan M Davis wrote:
On Tuesday, January 03, 2012 11:52:13 Matej Nanut wrote:
Hello everyone,
I would like to know whether
if (symbol in symbols)
return
On 01/03/2012 12:22 PM, Jonathan M Davis wrote:
On Tuesday, January 03, 2012 12:13:45 Timon Gehr wrote:
On 01/03/2012 12:07 PM, Jonathan M Davis wrote:
On Tuesday, January 03, 2012 11:52:13 Matej Nanut wrote:
Hello everyone,
I would like to know whether
if (symbol in symbols)
On Tuesday, January 03, 2012 12:27:08 Timon Gehr wrote:
No, I love declaring variables in if statements and would like it to be
extended to while statements as well. What I meant is the fact that
something called 'in' returns a pointer. And the two code snippets I was
referring to were the two
On 01/03/2012 04:07 AM, Jonathan M Davis wrote:
On Tuesday, January 03, 2012 11:52:13 Matej Nanut wrote:
Hello everyone,
I would like to know whether
if (symbol in symbols)
return symbols[symbol];
is any less efficient than
auto tmp = symbol in symbols;
On 3 January 2012 17:58, Kai Meyer k...@unixlords.com wrote:
On 01/03/2012 04:07 AM, Jonathan M Davis wrote:
if(auto tmp = symbol in symbols)
return *tmp;
- Jonathan M Davis
+1
Very slick :)
Yup, I'm going with this one. Thanks!
On 01/03/2012 02:52 AM, Matej Nanut wrote:
I would like to know whether
if (symbol in symbols)
return symbols[symbol];
is any less efficient than
auto tmp = symbol in symbols;
if (tmp !is null)
return *tmp;
Without