Code::Blocks Forums
User forums => Using Code::Blocks => Topic started by: candy.chiu.ad on April 26, 2012, 04:11:28 pm
-
Hi,
The compilation errors I received in Build Log seem to be incomplete. For example, one of them is
C:\DiskE\cpp\LanguageTestGcc47\variadic_template.cpp: In instantiation of 'void Printer::doIt(T&&) [with T = double]':
C:\DiskE\cpp\LanguageTestGcc47\variadic_template.cpp:52:9: recursively required from 'void Printer::operator()(H&&, T&& ...) [with H = int; T = {double}]'
C:\DiskE\cpp\LanguageTestGcc47\variadic_template.cpp:52:9: required from 'void Printer::operator()(H&&, T&& ...) [with H = const int&; T = {int, double}]'
C:\DiskE\cpp\LanguageTestGcc47\variadic_template.cpp:89:5: required from 'void callNormalize(F, T&& ...) [with F = Printer; T = {const int&, int, double}]'
C:\DiskE\cpp\LanguageTestGcc47\variadic_template.cpp:96:39: required from here
C:\DiskE\cpp\LanguageTestGcc47\variadic_template.cpp:61:14: warning: value computed is not used [-Wunused-value]
While it printed out the stack trace, I don't know what the error is. Am I missing something here? I don't enough information to debug my program.
Thanks,
Candy
-
I think those are just warning and informational messages.
The "required from" are new in gcc 4.7; Code::Blocks thinks they are errors but they are not.
Tim S.
-
But the code didn't successfully compile, and therefore, is not executable. How should I configure CodeBlocks to get rid of the "errors"?
-
If you're using gcc-4.7 then you should be ready for some breakages.
Install gcc-4.6 and everything will be fine.
If you're interested in using gcc-4.7 you have to add some regular expressions to match the new output.
This is done in the Settings -> Compiler -> Other -> Advanced options -> Output parsing.
p.s. Please next time follow the forum rules and post some info about your os/compiler/c::b versions. Our supplier of magic balls is out of stock and we are unable to guess all this info! :-P
-
Note: In gcc 4.7 Adding the "-fpermissive" compiler flag should stop most of the "required from" items from being errors.
Tim S.
-
Thanks and sorry for the missing information.
-
But you have not provided it again. Why?