pierre3 / PlantUmlClassDiagramGenerator

This is a generator to create a class-diagram of PlantUML from the C# source code.
MIT License
654 stars 129 forks source link

Make generic types more readable: MyType`2 => MyType<T1,T2> #80

Open CodeSmile-0000011110110111 opened 1 year ago

CodeSmile-0000011110110111 commented 1 year ago

Since generic types are suffixed with backtick followed by the number of arguments it makes for difficult reading. This system exists solely to support the compiler, not humans.

Therefore I wish at least an option (if not default behaviour) that generic types are reprinted in a form that we expect from looking at the code.

Instead of: MyType`2

The output should be: MyType<T1,T2>

Of course if the actual type names used in the code would be preserved that would be even better, like so: MyType<TKey,TValue>

All of a sudden you realize that this is probably some kind of dictionary, which you couldn't infer from the two versions above.

CodeSmile-0000011110110111 commented 1 year ago

I hacked this into my fork.