ShellFile
implements IDisposable
.
public string LocalizedName => new ShellFile(Executable).FileDescription;
I was unable to find anything on the internet about using disposable objects in expression-bodied members.
Is the ShellFile
instance correctly disposed, or should I do something like this ?
public string LocalizedName
{
get
{
using ShellFile shellFile = new(Executable);
return shellFile.FileDescription;
}
}