Code::Blocks Forums

User forums => General (but related to Code::Blocks) => Topic started by: Pitti on August 12, 2014, 05:29:15 pm

Title: Getting wrong error line with vc++
Post by: Pitti on August 12, 2014, 05:29:15 pm
Hi,

I'm a little confused. I'm working with Code::Blocks 13.12 and a Visual C++ (2011) toolchain to compile a DLL Runtime Library. In fact, everything is working fine, except the build message log. When something is wrong in my code I'm getting a correct compiler error message, but referring to the wrong line of code. Eg. line 145 instead 248. I played around with some compiler flags like disabling optimizations and so on, but no luck.

Any ideas?

Thanks in advance,
Peter
Title: Re: Getting wrong error line with vc++
Post by: stahta01 on August 12, 2014, 06:24:52 pm
Post the build log with the warning in it.
NOTE: Build log NOT the Build message!

Edit: The Advanced Compiler settings likely need to be changed for the warning.

Tim S.
Title: Re: Getting wrong error line with vc++
Post by: Pitti on August 12, 2014, 06:40:50 pm
Code
-------------- Build: Maya 2015 Release Win64 in raycastPointCmd (compiler: Microsoft Visual C++ 2011 x64)---------------

x86_amd64\cl.exe /nologo  /MTd /EHac /DWIN64 /D_CONSOLE /DNT_APP /DREQUIRE_IOSTREAM /DNT_PLUGIN   /IE:\Coding\CodeBlocks\..\MayaRessources\Maya2015.x64\include /I"E:\Coding\CodeBlocks\..\Microsoft\Microsoft SDKs\Windows\v7.1\include" /I"E:\Coding\CodeBlocks\..\Microsoft\Microsoft Visual Studio 11.0\VC\include" /c src\raycastPointCmd.cpp /FoRelease\Maya2015.x64\src\raycastPointCmd.obj
raycastPointCmd.cpp

src\raycastPointCmd.cpp(145) : error C2039: 'length': Ist kein Element von 'MItSelectionList'

The error message itself is eligible, but the correct line of code should be 277 not 145. Sorry, the error message is in german. I've trouble to get the cl.exe output in english. Maybe the compiler itself is the problem, but I've no idea what's going on.

Thank you,
Peter

Title: Re: Getting wrong error line with vc++
Post by: Jenna on August 12, 2014, 06:53:50 pm
So it's not Code::Blocks that is wrong, but your compiler gives an incorrect output.

That means your question is out of the scope of this forum/website and therefore violates our forum rules.
Title: Re: Getting wrong error line with vc++
Post by: Pitti on August 12, 2014, 07:01:01 pm
Ok, sorry for that.

Nevertheless, I thank you.

Peter