Tell VS2010 the collapse of the regions

So, I wrote a t4 template that generates a ton of code and works well. The only problem is that most of the code should never be noticed by developers, so I hid all boiler plate code in the regions. Is there any way (I suppose not) to give VS a hint in a C ++ code file to move forward and collapse regions.

+4
source share
2 answers

You can generate the code in a separate file, and then #include where necessary. Thus, you will not have developers working directly on the generated code: they do not see them, and this facilitates future restorations of this code.

+2
source

Use # pragma region . It will not have regions hidden by default, but it will allow you to collapse several functions at the same time.

+1
source

All Articles