【问题标题】:Indentation for initializer list in Constructor is wrong构造函数中初始化列表的缩进是错误的
【发布时间】:2014-01-28 00:27:36
【问题描述】:

我正在使用emacs 24.3,但我在使用 emacs 缩进引擎和新的 C++11 初始值设定项列表时遇到了以下问题。让我举个例子:考虑一个类Class,它有一个类型为std::vector<int> 的成员名为m_vector。 Emacs 将构造函数缩进如下:

Class() : m_vector( { 1,
            2,
            3 } ){ }

而我期望这种语法:

Class() : m_vector( { 1,
                      2,
                      3 } ){ }

有没有简单的解决方法?

【问题讨论】:

  • 好问题。我对此表示怀疑。我还发现 emacs 无法以我希望的方式支持多个 C++11 功能。

标签: c++ c++11 emacs indentation cc-mode


【解决方案1】:

所以提交一个错误。

GNU Emacs 的错误跟踪器在这里:http://debbugs.gnu.org/Emacs.html

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2013-10-03
    • 1970-01-01
    • 2014-07-14
    • 2017-03-07
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多