How to disable block comment autocomplete?
Answered
In some recent update, typing /* in Rider now automatically inserts a */ -- how can I disable this? I tried searching through the (very numerous) settings and was unable to find anything. It's making me crazy.
Please sign in to leave a comment.
Hi John!
I wasn't able to reproduce the issue as is. Could you please tell me some more details?
Which Rider version do you use (please check in `Help | About`), what is your OS, and in which type of files do you see this behavior?
Thanks!
I should have noted that I am editing .cpp files (Rider for Unreal Engine). That made me think to try it in a .cs file and it did not have this behavior, so it's something language specific I guess.
JetBrains Rider 2022.3.1
Build #RD-223.8214.53, built on December 20, 2022
Licensed to xxxx
Subscription is active until May 11, 2023.
Runtime version: 17.0.5+1-b653.23 amd64
VM: OpenJDK 64-Bit Server VM by JetBrains s.r.o.
Windows 10 10.0
.NET 7.0.0 (Server GC)
GC: G1 Young Generation, G1 Old Generation
Memory: 6000M
Cores: 32
Registry:
debugger.watches.in.variables=false
indexing.enable.entity.provider.based.indexing=false
ide.workspace.model.rbs.as.tree=false
vcs.empty.toolwindow.show=false
database.show.search.tab=false
platform.projectModel.workspace.model.file.index=false
rdclient.asyncActions=false
ide.new.project.model.index.case.sensitivity=true
Non-Bundled Plugins:
com.jetbrains.rider.ezargs (1.0.15)
Hi John,
Unfortunately, there is currently no option to disable the auto-insertion of */. I've created a ticket in YouTrack: https://youtrack.jetbrains.com/issue/RSCPP-33855. You can upvote or follow the ticket to get a notification when the option is available.
Sorry for the inconvenience.
You can turn off "Correct common language-specific typos" to turn off auto-insertion of */. Could you please describe why you want to disable this typing assist, what's your use case where it does not help you?
99% of the time I use a block comment it's to comment out a section of code, so I just have to delete the */ and put it where I really want it. I also do not enjoy most auto-completions of closing parens, brackets, etc., which is more just personal preference I guess. It's also a bit strange that there's a difference in behavior between .cs and .cpp files. I would expect consistency there given comments work the same between the languages.
We've discussed it and decided to put the behavior under an option for the sake of consistency. Originally the behavior was added since Visual Studio provides the same typing assist in C++, and we wanted to improve on it. Regardless, if you want to comment out a block of code, Rider provides a separate action exactly for this purpose - "Comment/uncomment with block comment" (Ctrl+Shift+/).
Thanks. Disabling the typo correction thing did work as you said, but it will be nice to have a separate option!