Re: 7 bit char

From: Alberto Barbati (AlbertoBarbati_at_libero.it)
Date: 02/29/04


Date: Sun, 29 Feb 2004 01:47:32 GMT

TK wrote:
> It's as if char now is a signed datatype,
> which it has never been before. I am developing in MS DevStudio 6.0.
> Is there a setting somewhere that could have been changed? I have
> never seen this before, and I have coded for about 10 years.

Which compiler did you use before? As far as I remember, char has always
been a signed datatype by default on Microsoft compilers as well as many
other C/C++ compilers I happened to work with in the last 17 years.

BTW, you can tell MSVC to make char unsigned by using the /J option.

Regards,

Alberto Barbati



Relevant Pages

  • Re: need a tiny help with my SWIGd program
    ... void setitem(int i, char* value) { ... underscore followed by an uppercase letter is reserved to the ... implementation for use as a name in the global namespace." ... compilers are more forgiving than the stantards: ...
    (comp.lang.tcl)
  • Re: String reversing problem
    ... >> To Mr. Christian Bau: ... > Nothing wrong with my english. ... Declare char here, far of the semantically parent of it it ... And lots of compilers will ignore it (no ...
    (comp.lang.c)
  • Re: It works without stdio.h !!
    ... most C compilers will assume that a function that has no prototype is an ... extern int, and since you only specify functions that live in the C library, an unresolved ... never declare a variable of type char unless you well and truly believe you need to be ... strcpy, strcat, sprintf etc. with it. ...
    (microsoft.public.vc.mfc)
  • Re: gcc4 and lvalues
    ... > I am trying to compile a C program (that used to work fine with gcc 2.x.y, ... On the assignment to s, callocreturns a void* which is implicitly ... converted to char*. ... other compilers weren't catching these errors. ...
    (comp.std.c)
  • Re: Purchase microcontroller dev. kit
    ... char b; ... Some very smart and expensive compilers may be able to solve ... line interpreter (a little more than a string compare on a list with ... Having a command line interface is also ...
    (sci.electronics.design)