On 2012-04-30 12:29, Manu wrote:
On 30 April 2012 10:39, Jacob Carlborg <[email protected] That's the only thing I used the with-statement for.That's the only thing I was aware it did ;) .. are there other uses?
You can use it to access members without a receiver as well:
class Foo
{
int x;
int y;
}
auto foo = new Foo;
with (foo)
{
x = 3;
y = 4;
}
http://dlang.org/statement.html#WithStatement
--
/Jacob Carlborg
