On FreeBSD, this fails (and many subsequent similar errors) :
DROD30/DROD/CharacterDialogWidget.cpp: In member function `void CCharacterDialogWidget::SetCommandParametersFromWidgets()':
/usr/users/drod/trunk/DROD30/DROD/CharacterDialogWidget.cpp:3777: error: cannot convert `const __gnu_cxx::character<WCHAR_t, int, mbstate_t>' to `__ct_rune_t' for argument `1' to `int __isctype(__ct_rune_t, long unsigned int)'
line 3777:
if (!this->pCommand->w && (!iswdigit(pOperandText[0]) || WCSlen(pOperandText) > 1))
this->pCommand->label = pOperandText;
It's failing on the "
iswdigit"
which seems rather correct to me, seeing as the definition is:
const WCHAR *pOperandText;
int iswdigit(wint_t wc);
I basically reduced the whole thing to this:
#include <stdio.h>
#include <wctype.h>
#include <ext/pod_char_traits.h>
main()
{
using namespace std;
using namespace __gnu_cxx;
typedef unsigned short WCHAR_t;
typedef character<WCHAR_t, int> WCHAR; //wc, 16-bit UNICODE character
WCHAR *smeg;
if (!iswdigit(smeg[0])) printf ("boo\n");
}
, which gives the same error, and a similar one on a linux machine I tried it on:
freebsd:
test.cc:17: error: cannot convert `__gnu_cxx::character<main::WCHAR_t, int, mbstate_t>' to `__ct_rune_t' for argument `1' to `int __isctype(__ct_rune_t, long unsigned int)'
linux:
test.cc:17: error: cannot convert ‘__gnu_cxx::character<short unsigned int, int, __mbstate_t>’ to ‘wint_t’ for argument ‘1’ to ‘int iswdigit(wint_t)’
Again, this looks expected to me, so what am I missing ? How come the source compiles on Linux in this state ?
Cheers,
J.
____________________________
#f3i2g#
Disclaimer: I'm Welsh, left-handed, and stupid.
#f3i2g#