News for hackers. Stuff that matters.
Re:How to C in 2016 by to3m on Friday January 08, 2016 @01:50PM (#10867196)
The sized types are optional, since they are more restrictive than the ordinary types - see section 7.20.1.1 in the standard (http://port70.net/~nsz/c/c11/n1570.html#7.20.1.1). To summarize: intN_t is exactly N bits, with zero padding bits, and 1 2's complement sign bit; uintN_t is exactly N bits, with zero padding bits; the implementation must provide such typedefs for all such types it supports.

So, if a system is 1's complement, you won't get the intN_t types at all. If the system doesn't support a particular bit width, you won't get the types for that width.

Re:How to C in 2016 by bsder on Friday January 08, 2016 @09:41PM (#10869837)
> So, if a system is 1's complement

As someone who actually programmed a 1's complement system with end-around carry, I'm going to call you out on this.

What system still exists that can run C99 and is one's complement?

Re:How to C in 2016 by to3m on Friday January 08, 2016 @10:11PM (#10869919)
I am playing the language lawyer game - there is nothing to call out. Is what I say justified by the standard? Yes, or no? There are no other issues involved ;)

I have no idea if C99 runs on any 1's complement systems. I don't know what end-around carry is. I don't care what it is. I don't care about any of this 1's complement nonsense. But the standard says it exists, and must be taken into account, and, therefore, by the rules of the game, I am obliged to assume these things.