CLion 中出现一些奇怪的自动缩进,我不明白为什么。这是一个例子
int i1(5); // some comments, then I hit Enter
// auto indentation goes here. I hit Enter again
// It goes here
float f = 5; // some comments, then I hit Enter
// then auto indentation goes here. I hit Enter again
// It then goes here.
float f2 = 6;
// If I don't comment on the previous line, there is no weird indentation
似乎每当我使用 = 初始化变量,然后在行末尾添加注释时,它都会在下一行上给我额外的缩进。但在所有其他情况下,它不会给我额外的缩进。
我最近安装了 CLion,它使用默认代码风格。似乎额外的缩进是由连续缩进设置控制的,但我只希望此连续缩进设置应用于代码,而不是注释。在使用 = 进行赋值时,我可以在哪里更改设置以禁用注释的连续缩进?
此错误已在 CLion 2018.2 EAP 中修复(https://www.jetbrains.com/clion/nextversion/ https://www.jetbrains.com/clion/nextversion/ ).
由于这个错误,我个人卸载了 CLion 2018.1,因为 EAP 足够稳定。
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)