#include<iostream>
using namespace std;
class Example
{
public:
Example(int a,int b,int c):m_a(a),m_b(b),m_c(c)
{ // Wrong indentation here due to the colon in above line, { should be under E
printf("\nThe 3 argument constructor invoked\n");
} // Wrong indentation again
private:
int m_a;
int m_b;
int m_c;
};
Run Code Online (Sandbox Code Playgroud)
大家好,
我在C++的构造函数初始化列表中的gvim缩进中遇到了一些问题.我在.gvimrc中使用了cindent,即使多次更改我的.gvimrc,我也无法解决这个问题.
一些仁慈的灵魂能给我一些方法来设置它.我试过改变cinoptions和cinwords,但没有什么真正帮助.
我在上面提供的代码段中突出显示了缩进问题.
谢谢你的耐心
关心lali