As requested here are some warnings. It seems the Db*.cpp files are currently the weirdest
I've been guessing the type to cast to (explained in the following list) so please let me know if I am way off mark ( and I did guess
)
The following are all from DRODLib.
------------------
DbDemos.cpp: In member function `void CDbDemos::LoadMembership_ByShow()':
DbDemos.cpp:497: warning: choosing `CAttachableWrapper<
T>
::operator T&() [with
T = UINT]' over `CAttachableWrapper<
T>
::operator T() const [with T = UINT]'
DbDemos.cpp:497: warning: for conversion from `CAttachableWrapper<
UINT>
' to `
unsigned int'
DbDemos.cpp:497: warning: because conversion sequence for the argument is
better
DbDemos.cpp: In function `bool GetDemoStatBool(const CIDList&, long unsigned
int)':
DbDemos.cpp:1352: warning: choosing `CAttachableWrapper<
T>
::operator T&() [with
T = bool]' over `CAttachableWrapper<
T>
::operator T() const [with T = bool]'
DbDemos.cpp:1352: warning: for conversion from `CAttachableWrapper<
bool>
' to
`bool'
DbDemos.cpp:1352: warning: because conversion sequence for the argument is
better
DbDemos.cpp: In function `UINT GetDemoStatUint(const CIDList&, long unsigned
int)':
DbDemos.cpp:1364: warning: choosing `CAttachableWrapper<
T>
::operator T&() [with
T = UINT]' over `CAttachableWrapper<
T>
::operator T() const [with T = UINT]'
DbDemos.cpp:1364: warning: for conversion from `CAttachableWrapper<
UINT>
' to
`unsigned int'
DbDemos.cpp:1364: warning: because conversion sequence for the argument is
better
------------------
DbPackedVars.cpp: In member function `void CDbPackedVars::Clear()':
DbPackedVars.cpp:85: warning: deleting `void*' is undefined
DbPackedVars.cpp: In member function `void* CDbPackedVars::SetVar(const char*,
const void*, long unsigned int)':
DbPackedVars.cpp:255: warning: deleting `void*' is undefined
g++ -c -g -D_DEBUG -I/Users/ross/Devel/include/ -I/Users/ross/Devel/include/SDL -I. -c DbPlayers.cpp -o DbPlayers.o
DbPlayers.cpp:36:2: #error The byte order of several data-types may differ.
DbPlayers.cpp: In member function `std::string CDbPlayers::ExportXML(long
unsigned int, CDbRefs&, bool)':
DbPlayers.cpp:193: warning: name lookup of `dwIndex' changed for new ISO `for'
scoping
DbPlayers.cpp:183: warning: using obsolete binding at `dwIndex'
DbPlayers.cpp: In member function `bool CDbPlayer::Load(long unsigned int)':
DbPlayers.cpp:393: no match for `CDbPackedVars& = c4_BytesRef' operator
DbPackedVars.h:77: candidates are: const BYTE* CDbPackedVars::operator=(const
BYTE*)
DbPackedVars.h:79: c4_BytesRef&
CDbPackedVars::operator=(c4_BytesRef&)
DbPackedVars.h:70: CDbPackedVars&
CDbPackedVars::operator=(const CDbPackedVars&)
------------------
DbPlayers (35) Non window/Intel platforms must change this. This means me.
------------------
DbPlayers.cpp: In member function `std::string CDbPlayers::ExportXML(long
unsigned int, CDbRefs&, bool)':
DbPlayers.cpp:193: warning: name lookup of `dwIndex' changed for new ISO `for'
scoping
DbPlayers.cpp:183: warning: using obsolete binding at `dwIndex'
DbPlayers.cpp: In member function `bool CDbPlayer::Load(long unsigned int)':
DbPlayers.cpp:393: no match for `CDbPackedVars& = c4_BytesRef' operator
DbPackedVars.h:77: candidates are: const BYTE* CDbPackedVars::operator=(const
BYTE*)
DbPackedVars.h:79: c4_BytesRef&
CDbPackedVars::operator=(c4_BytesRef&)
DbPackedVars.h:70: CDbPackedVars&
CDbPackedVars::operator=(const CDbPackedVars&)
Guessed at (c4_BytesRef&)
______________________
DbRooms.cpp: In member function `void CDbRoom::SetExit(unsigned int, unsigned
int, long unsigned int)':
DbRooms.cpp:1565: warning: name lookup of `i' changed for new ISO `for' scoping
DbRooms.cpp:1539: warning: using obsolete binding at `i'
DbRooms.cpp: In member function `bool CDbRoom::LoadMonsters(c4_View&)':
DbRooms.cpp:2053: no match for `CDbPackedVars& = c4_BytesRef' operator
DbPackedVars.h:77: candidates are: const BYTE* CDbPackedVars::operator=(const
BYTE*)
DbPackedVars.h:79: c4_BytesRef&
CDbPackedVars::operator=(c4_BytesRef&)
DbPackedVars.h:70: CDbPackedVars&
CDbPackedVars::operator=(const CDbPackedVars&)
DbRooms.cpp: In member function `void CDbRoom:
eleteOrbAtSquare(unsigned int,
unsigned int)':
DbRooms.cpp:2257: warning: name lookup of `wOrbI' changed for new ISO `for'
scoping
DbRooms.cpp:2246: warning: using obsolete binding at `wOrbI'
DbRooms.cpp: In member function `void
CDbRoom:
eleteScrollTextAtSquare(unsigned int, unsigned int)':
DbRooms.cpp:2282: warning: name lookup of `wScrollI' changed for new ISO `for'
scoping
DbRooms.cpp:2270: warning: using obsolete binding at `wScrollI'
DbRooms.cpp: In member function `void CDbRoom::SetScrollTextAtSquare(unsigned
int, unsigned int, WCHAR*)':
DbRooms.cpp:2376: warning: name lookup of `wScrollI' changed for new ISO `for'
scoping
DbRooms.cpp:2362: warning: using obsolete binding at `wScrollI'
DbRooms.cpp: In member function `bool CDbRoom::IsTarVulnerableToStab(unsigned
int, unsigned int) const':
DbRooms.cpp:2634: warning: name lookup of `i' changed for new ISO `for' scoping
DbRooms.cpp:2611: warning: using obsolete binding at `i'
DbRooms.cpp: In member function `void CDbRoom:
lot(unsigned int, unsigned int,
unsigned int, CMonster*)':
DbRooms.cpp:3172: warning: name lookup of `eMovement' changed for new ISO `for'
scoping
DbRooms.cpp:3139: warning: using obsolete binding at `eMovement'
___________________
DbSavedGames.cpp: In member function `bool CDbSavedGame::Load(long unsigned
int)':
DbSavedGames.cpp:103: no match for `CDbCommands& = c4_BytesRef' operator
DbCommands.h:57: candidates are: const BYTE* CDbCommands::operator=(const
BYTE*)
DbCommands.h:59: c4_BytesRef&
CDbCommands::operator=(c4_BytesRef&)
DbCommands.h:87: CDbCommands& CDbCommands::operator=(const
CDbCommands&)
___________________
DbXML.cpp: In static member function `static MESSAGE_ID CDbXML::ImportXML(const
WCHAR*)':
DbXML.cpp:543: `UCHAR' undeclared (first use this function)
DbXML.cpp:544: `ULONG' undeclared (first use this function)
DbXML.cpp:546: `B' undeclared (first use this function)
Following needed in Types.h
typedef unsigned long ULONG;
typedef unsigned char UCHAR;
______________________
Goblin.cpp: In member function `void CGoblin::GetNormalMovement(int&, int&,
int&, int&) const':
Goblin.cpp:127: call of overloaded `abs(unsigned int)' is ambiguous
/usr/include/stdlib.h:108: candidates are: int abs(int)
/usr/include/gcc/darwin/3.1/g++-v3/cstdlib:119: long int
std::abs(long int)
Goblin.cpp:128: call of overloaded `abs(unsigned int)' is ambiguous
/usr/include/stdlib.h:108: candidates are: int abs(int)
/usr/include/gcc/darwin/3.1/g++-v3/cstdlib:119: long int
std::abs(long int)
______________________
Monster.cpp: In member function `bool CMonster::IsSwordsmanWithin(unsigned int)
const':
Monster.cpp:207: call of overloaded `abs(unsigned int)' is ambiguous
/usr/include/stdlib.h:108: candidates are: int abs(int)
/usr/include/gcc/darwin/3.1/g++-v3/cstdlib:119: long int
Several times. Note that nDist in GameConstants.h also uses abs() and needs the cast.
--------------------
Serpent.cpp: In member function `virtual void
CSerpent::GetBrainDirectedMovement(int&, int&, int&, int&) const':
Serpent.cpp:233: call of overloaded `abs(long unsigned int)' is ambiguous
/usr/include/stdlib.h:108: candidates are: int abs(int)
/usr/include/gcc/darwin/3.1/g++-v3/cstdlib:119: long int
std::abs(long int)
Serpent.cpp:233: call of overloaded `abs(long unsigned int)' is ambiguous
/usr/include/stdlib.h:108: candidates are: int abs(int)
/usr/include/gcc/darwin/3.1/g++-v3/cstdlib:119: long int
std::abs(long int)
--------------------
IniFile.cpp: In member function `bool CIniFile::Load(const WCHAR*)':
IniFile.cpp:198: `isspace' undeclared (first use this function)
IniFile.cpp:198: (Each undeclared identifier is reported only once for each
function it appears in.)
make: *** [IniFile.o] Error 1
Following should fix
#ifndef __Win32
#include <
ctype.h>
#endif
--------------------
[Edited by ross on 05-19-2003 at 10:14 PM]