public class Disposable : IDisposable
public int Property { get => _property; set => throw new Exception(); }
Console.WriteLine("Disposed");
public static void Main()
using (var resource = new Disposable())
using (var resource = new Disposable() { Property = 1 })