C#C
C#4y ago
OmegaLol21

Difference between variable using and statement using?

Im just wondering if there is any difference to using a using statement by doing this:
using var foo = new Bar();
foo.DoStuff();

as opposed to doing
using (var foo = new Bar())
{
    foo.DoStuff();
}
Was this page helpful?