:<built-in>1:2: 警告:使用 C++0x 长整型整数常量 [-Wlong-long]



这是什么警告?它似乎在警告内置的long - long常量。这是来自GCC 4.7.3版本(Ubuntu/Linaro 4.7.3-1ubuntu1)。

In file included from ../include/log4cplus/helpers/stringhelper.h:36:0,
                 from ../tests/performance_test/main.cxx:6:
<built-in>:1:2: warning: use of C++0x long long integer constant [-Wlong-long]

您可以按照Daniel Fischer的建议使用新的c++ 11标准。但是,如果您正在交叉编译或使用较旧的编译器:

-Wno-long-long

是一个有效的编译器标志,它将禁止警告(当然只是来自man gcc)。

最新更新