DUPE: Uses of "using" in C#
I have seen people use the following and I am wondering what is its purpose? Is it so the object is destroyed after its use by garbage collection?
Example:
using (Something mySomething = new Something()) {
mySomething.someProp = "Hey";
}