controlflow / resharper-heapview

ReSharper Heap Allocations Viewer plugin
MIT License
303 stars 28 forks source link

Should be "possible" boxing allocation when casting from T to object #62

Closed RogerKratz closed 4 years ago

RogerKratz commented 5 years ago

This snippet gives "boxing allocation"...

public class Foo<T> 
{
    public object Bar(T fooo)
    {
        return fooo;
    }
}

Shouldn't it rather be "possible boxing allocation" (depending on T is a value or ref type in runtime)?