private static bool IsAnonymousType (Type type) { return type.IsDefined (typeof (CompilerGeneratedAttribute), false); }