BADF00D / DisposableFixer

This is a Visual Studio Extension and NuGet package that should identify and fix problems as memleaks while using IDisposables.
Other
35 stars 7 forks source link

Func that returns IDisposable should be ignored in version 0.22 #43

Closed dscopra closed 7 years ago

dscopra commented 7 years ago

The following func should not yield an error, because the disposable is directly returned.

using System;
using System.IO;
namespace Disposeables {
    class Program {
        static void Main(string[] args) {
            Func<MemoryStream> openStream = () => new MemoryStream();
        }
    }
}

image