Why does VS2022 keep adding * after I type /*?

Jason Hay 20 Reputation points
2023-02-28T21:26:58.0166667+00:00

Why does VS2022 keep adding * after I type /*?

So annoying

Developer technologies | C++
Developer technologies | C++

A high-level, general-purpose programming language, created as an extension of the C programming language, that has object-oriented, generic, and functional features in addition to facilities for low-level memory manipulation.

Developer technologies | Visual Studio | Other
Developer technologies | Visual Studio | Other

A family of Microsoft suites of integrated development tools for building applications for Windows, the web, mobile devices and many other platforms. Miscellaneous topics that do not fit into specific categories.

Locked Question. You can vote on whether it's helpful, but you can't add comments or replies or follow the question.

Answer accepted by question author
Michael Taylor 61,236 Reputation points
2023-02-28T21:39:53.46+00:00

If you mean on the next line like this:

/*
 *

Then that is because most block-styled languages follow the pattern of putting an asterisk on each new line so multiline comments indent to the same level. It is a consistency thing.

If you want to disable this convention for some reason then you can do so by going to Tools \ Options and then Text Editor \ C/C++ \ Code Style \ General and uncheck the Insert existing comment style option.

enter image description here

Was this answer helpful?

3 people found this answer helpful.

0 additional answers

Sort by: Most helpful