Thread: signed vs unsigned

  1. #1
    Registered User char's Avatar
    Join Date
    Apr 2002
    Posts
    31

    signed vs unsigned

    Hi

    I know that default characters may be either signed or unsigned. Is it the compiler that decides if a char will be signed or unsigned or is it more like it happens at runtime (platform dependent)?

    Thank you in advance !!

  2. #2
    and the hat of int overfl Salem's Avatar
    Join Date
    Aug 2001
    Location
    The edge of the known universe
    Posts
    39,659
    > Is it the compiler that decides if a char will be signed or unsigned
    No, it's the compiler writer who chooses

    Their choice may be based on what the target processor most easily implements, but at the end of the day, they have to implement signed and unsigned chars anyway.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Replies: 12
    Last Post: 08-11-2008, 11:02 PM
  2. Heap corruption using zlib inflate
    By The Wazaa in forum C++ Programming
    Replies: 0
    Last Post: 03-29-2007, 12:43 PM
  3. Replies: 16
    Last Post: 10-29-2006, 05:04 AM
  4. Obtaining source & destination IP,details of ICMP Header & each of field of it ???
    By cromologic in forum Networking/Device Communication
    Replies: 1
    Last Post: 04-29-2006, 02:49 PM