public inbox for gcc-help@gcc.gnu.org
 help / color / mirror / Atom feed
From: Michael Eager <eager@eagercon.com>
To: Ed Stafford <ed.stafford@xilinx.com>
Cc: John Love-Jensen <eljay@adobe.com>, GCC-help <gcc-help@gcc.gnu.org>
Subject: Re: Signedness of char and puts()
Date: Mon, 31 Mar 2008 17:28:00 -0000	[thread overview]
Message-ID: <47F11E0A.4010909@eagercon.com> (raw)
In-Reply-To: <20080331150543.AF81510A00B2@mail182-dub.bigfish.com>

Ed Stafford wrote:
> Thanks for the replies.
> 
> It does seem that gcc is treating them as 3 separate
> types. 
> 
> The compiler will treat plain char as signed or unsigned
> depending on the ABI, but even if the default is for char
> to act like unsigned char, it will warn you that char and
> unsigned char are of different types.
> 
>From the docs:
> 
> Which of signed char or unsigned char has the same range, 
> representation, and behavior as "plain" char. Determined by ABI. 
> The options '-funsigned-char' and '-fsigned-char' change the
> default.
> 
> It just seems that older versions of gcc didn't do this.
> 
> Does it seem I'm on the right track here?

Yes.  It appears that you will only get these messages
if you specify -Wall.  I don't see any messages on a
compile without the flag.

-- 
Michael Eager	 eager@eagercon.com
1960 Park Blvd., Palo Alto, CA 94306  650-325-8077

  reply	other threads:[~2008-03-31 17:28 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-03-28 20:04 Ed Stafford
2008-03-28 23:25 ` Eljay Love-Jensen
2008-03-29  1:04   ` me22
2008-03-29  1:19   ` Matthew Woehlke
2008-03-29 12:43     ` Eljay Love-Jensen
2008-03-31  9:15   ` Michael Eager
2008-03-31 11:44     ` John Love-Jensen
2008-03-31 14:56       ` Michael Eager
2008-03-31 15:06         ` Ed Stafford
2008-03-31 17:28           ` Michael Eager [this message]
2008-04-17  9:38   ` lynx.abraxas
2008-04-17 13:49     ` Eljay Love-Jensen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=47F11E0A.4010909@eagercon.com \
    --to=eager@eagercon.com \
    --cc=ed.stafford@xilinx.com \
    --cc=eljay@adobe.com \
    --cc=gcc-help@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).