Is there a good solution for compiler-generated code being marked Serializable?

C# in VS2015 seems to throw a pointless Serializable attribute onto some auto-generated code, causing the parent class not to be fully obfuscated. Is there a better solution than tweaking the code until the attribute stops appearing?

A user on stackoverflow ended up writing a custom tool to pre-process the assembly and strip the attribute. I'd rather not do that.

It would be nice if there was an option to force obfuscation for a class, but ideally SmartAssembly should have an option to ignore Serializable when CompilerGenerated is also present.


Sign In or Register to comment.