andrewlock / StronglyTypedId

A Rosyln-powered generator for strongly-typed IDs
MIT License
1.52k stars 80 forks source link

Mark generated code as generated code #57

Closed ahordijk closed 9 months ago

ahordijk commented 2 years ago

To prevent code analysis warnings and errors. Please add [System.CodeDom.Compiler.GeneratedCode(null, null)] to all generated code, with appropriated tool and version number.

SteveDunn commented 2 years ago

I added something similar to Vogen recently: https://github.com/SteveDunn/Vogen/pull/126

andrewlock commented 9 months ago

Done as part of the refactor in #117. Note that this marks the whole type as generated, even though it might not all be (because you might manually add additional implementation). It's probably ok though IMO, hence implementing it 😄