I often find myself in situations where I would like to indent preprocessor directives like the rest of the code (e.g. #if
indented like if
). It seems legal, it's common sense that it's sometimes a good thing, but Visual won't make it easy.
Is there a way to prevent the Visual C++ 2010 editor from sticking the code to the left each time I innocently press #
? And to not break preprocessor directives indentation with auto-indent (CTRL+K, CTRL+F)? Or even better, to handle preprocessor directives like everything else?