简体   繁体   中英

IntelliJ adds extra * every time I hit enter in a block comment

I'm having a super strange problem with Idea.

Every time I hit enter in a block comment it adds an extra * on the line. It gets really annoying to have to delete it before typing each line. I have tried importing several coworkers code style settings who are not having this issue to no avail. I also can't seem to find the setting that would be doing this, and nothing on google. Anyone know a setting that could be causing this?

Example:

 /**
 * Some comment (pressing enter 3 times)
 * 
 * 
 * (cursor is here)* * * * 
 */

Another Example:

/**
* Some comment (press enter)
* (cursor is here)*
*/

I suspect this is a defect/regression. I've created an issue on YouTrack: https://youtrack.jetbrains.com/issue/IDEA-136673


Update

The IntelliJ team isolated the issue to Gauge plugin. I've logged the issue with plugin authors: https://github.com/getgauge/Intellij-Plugin/issues/39

Looks like it's a bug in the Gauge plugin I was using for ".md" file support. Uninstalled that and the issue was gone.

https://youtrack.jetbrains.com/issue/IDEA-136182

What you're typing are not normal block comments (/* ... */) but Javadoc comments (/** ... */), and those should have a * at every line. So just delete the extra * after the first / and you'll be fine.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM