Game Development Community

Why do I get 12 warnings when compiling the Library?

by Daniel J Lee · in General Game Discussion · 11/29/2003 (5:11 pm) · 10 replies

Does anyone have similar problem. I mean I can use the library just fine, but I don't want to see any warnings at all. Let me know. Far as I know, I have setup my VC6 correctly with include and lib folder and such.

Thanks.

#1
11/29/2003 (11:41 pm)
Well........

what are the warnings cowboy?
#2
12/04/2004 (7:01 pm)
Hi,

It happens to me too. I just ignore it for now, but it should works fine.
Seems a pretty late reply.

Regards,
James Yong
#3
12/04/2004 (10:02 pm)
I missed this thread, sorry ...

It would help if you could tell us what the warnings are. Most warnings are usually OK to ignore, but cant say for sure without knowing what warnings you're getting.

Tom.
#4
12/05/2004 (12:16 am)
Example of one of the 12 warnings. The rest are similar.

C:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\vector(48) : warning C4786: '??0?$vector@V?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@V?$allocator@V?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@@2@@std@@QAE@IABV
?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@1@ABV?$allocator@V?$basic_string@DU?$char_traits@D@std@@V?$allocator@D@2@@std@@@1@@Z' : identifier was truncated to '255' characters in the browser information
        .\Includes\corona.h(364) : see reference to class template instantiation 'std::vector<class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >,class std::allocator<class std::basic_string<char,struct std::char_
traits<char>,class std::allocator<char> > > >' being compiled
#5
12/05/2004 (12:43 am)
Ah. There's nothing you can do about those. That's down to the STL, which Corona uses, using really long symbols that the browse information doesnt like. If you dont want to see those warnings (which are annoying in their unfixability) you can either disable browse info or stick this at the top of corona.h somewhere:

// Disable annoying warnings related to STL and browse info
#pragma warning(disable : 4786)

T.
#6
12/05/2004 (3:21 am)
Thanks for the info, Tom.
#7
12/06/2004 (9:20 am)
It's also worth noting that there is a known bug in VC 6.0 where disabling warning 4786 does not work. Sometimes it does, sometimes it doesn't.
#8
12/06/2004 (11:02 am)
Really ? Odd, it's always worked for me.
#9
12/08/2004 (9:10 am)
It's a weird voodoo thing. In a workspace with over 20,000 source files (with heavy STL use) there are about 3 files that refuse to stifle that warning no matter what we do.

http://support.microsoft.com/default.aspx?scid=kb;en-us;167355
#10
12/08/2004 (12:12 pm)
Ahh, I've never used the STL in a project that large, might be why I havent come up against it. I tend to studiously avoid the STL these days :)