The problem is that the compiler treats signed chars and chars differently,
it thinks there a three types of char,  1. signed char, 2. unsigned char, 3.
char. Not strictly wrong but a bit fussy

> -----Original Message-----
> From: [EMAIL PROTECTED] [SMTP:[EMAIL PROTECTED]]
> Sent: 28 July 2000 13:00
> To:   Palm Developer Forum
> Subject:      Re: Compiler - Cannot convert signed char * to char *
> 
> 
> Well, to avoid this kind of error you should only make an explicit  cast.
> Do you use SDK3.5?
> 
> Where the StrPrintF is going to put the output?
> 
> What you wrote:
> 
> 
> Hi
> 
> Anyone know why sometimes the compiler gives the error
> 
>   : cannot convert
> 'unsigned char *' to
> 'char *'
> 
> I then convert my unsigned char * ( UInt8 buffer [21] )
> to a char * ( Int8 buffer[21] ) and get
> 
> Error   : cannot convert
> 'signed char *' to
> 'char *'
> 
> I am using my buffer as follows
> 
> StrPrintF (buffer, "blah blah", blah);
> 
> Thanks
> 
> Rik
> 
> PS - The compiler also does not handle even word alligment correctly - ie
> if
> you point a UInt 16 * at an odd address and read it you get a bus error.
> Im
> sure that the complier should handle this !!!. Nasty bug to find as the
> emulator give 3 unprintable charaters in a dialogue box as an error.
> 
> 
> 
> 
> -- 
> For information on using the Palm Developer Forums, or to unsubscribe,
> please see http://www.palmos.com/dev/tech/support/forums/

-- 
For information on using the Palm Developer Forums, or to unsubscribe, please see 
http://www.palmos.com/dev/tech/support/forums/

Reply via email to