#37 NumToStr and unsigned long

compiler
open
NXC (53)
5
2013-01-02
2007-10-03
s4ll4c
No

// NumToStr has problems with unsigned long
task main()
{
string text;

int a = -1;
unsigned int b = -1;

long c = -1;
unsigned long d = -1;

text = NumToStr( a );
dbString( text ); // -1

text = NumToStr( b );
dbString( text ); // 65535

text = NumToStr( c );
dbString( text ); // -1

text = NumToStr( d );
dbString( text ); // -1 (unsigned long)

dbKey();
}

Discussion

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:

JavaScript is required for this form.





No, thanks