avr-gcc-list
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [avr-gcc-list] Passing a string variable to lcd_puts


From: David Kelly
Subject: Re: [avr-gcc-list] Passing a string variable to lcd_puts
Date: Fri, 27 Mar 2009 15:15:58 -0500
User-agent: Mutt/1.4.2.3i

On Fri, Mar 27, 2009 at 04:06:21PM -0400, David VanHorn wrote:
> >
> > In C there are 3 char types.  "char" "signed char" "unsigned char"  so
> > maybe "char" isn't signed?
> 
> Ok, so that leaves me VERY confused..

As you should be. Plain old "char" *is* either signed or unsigned
depending on your choice of compiler. And in effort to build code that
runs as expected better compilers have a compile time switch to control
code generation when the signedness is specifically indicated.

See -funsigned-char, -fsigned-char, and -fno-unsigned-char in the
avr-gcc man page.

So in short plain old "char" is only being sloppy in not explicitly
stating signed or unsigned.

-- 
David Kelly N4HHE, address@hidden
========================================================================
Whom computers would destroy, they must first drive mad.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]