Checking if generic parameter is enum for nullable type
I come across a bug in a method we have in our projects at work. The method takes a generic type and then it checks if the type is enum before it applies further logic to it. If the type is not an enum, it will throw an ArgumentException. The method is similar to the … [Read more…]