Skip to content

Instantly share code, notes, and snippets.

@ilkerde
ilkerde / gist:838709
Created February 22, 2011 14:08
I wonder whether introducing such an extension is considered a smell. For me it's most likely a smell.
using System;
namespace Is.This.A.Smell {
public static class EnumExtensions {
public static string AsString(this Enum e) {
return Enum.GetName(e.GetType(), e);
}
}
}