Closed everpcpc closed 10 years ago
在gentoo下编译Config.cpp文件的时候会出现Lambda function的错误,稍微查了一下,官方的使用c++11 lambda expressions 的connect函数的例子是如下: http://qt-project.org/wiki/New_Signal_Slot_Syntax
connect(sender, &Sender::valueChanged, tr1::bind(receiver, &Receiver::updateValue, "senderValue", tr1::placeholder::_1) ); connect(sender, &Sender::valueChanged, [=](const QString &newValue) { receiver->updateValue("senderValue", newValue); } );
于是对代码进行了如下的更改 b9671d11a3fac983f8fa1bcf37b9d984b5f99526 然后便可以正常编译。(不过没有理解是为什么……
错误是由于GCC版本过低,参见 c77cb2e392a9f072516af159d619f6e4dcfa9359
在gentoo下编译Config.cpp文件的时候会出现Lambda function的错误,稍微查了一下,官方的使用c++11 lambda expressions 的connect函数的例子是如下: http://qt-project.org/wiki/New_Signal_Slot_Syntax
于是对代码进行了如下的更改 b9671d11a3fac983f8fa1bcf37b9d984b5f99526 然后便可以正常编译。(不过没有理解是为什么……