[英]Can't complete `auto` variable of C++11 in Code::Blocks
This problem is very easy to encounter, but very hard to describe. 这个问题很容易遇到,但是很难描述。 I use Code::Blocks 13.12, test the code snippet as follows:
我使用Code :: Blocks 13.12,按如下所示测试代码段:
auto xxx = std::string("test");
xxx.
When the trailing .
当尾随
.
is entered, there should be a context menu of auto completion popup, but it doesn't. 输入后,应该有一个自动完成弹出窗口的上下文菜单,但是没有。
But if I give the right type of xxx
like that: 但是,如果我给出正确的
xxx
类型,例如:
std::string xxx = std::string("test");
xxx.
The complete menu pops up as normal. 正常弹出完整菜单。 Does the completion feature not support C++11 yet?
完成功能还不支持C ++ 11吗? Or it just can't complete the
auto
type? 还是无法完成
auto
输入?
转到“设置”->“编译器”,找到带有编译器标志-std = c ++ 11的C ++编译器,选择该标志并保存。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.