News for hackers. Stuff that matters.
Re:C (Cbang) - A system oriented programming language by alexchamberlain on Wednesday May 09, 2012 @10:19AM (#3948665)
I have a couple of problems with their analysis of C.

There's no typed macros

There are inlined functions...

While the type system of C is basically size based, a lot of types have an ambiguous size (int for example)

Use stdint.h definitions.

Having said that, I would like namespaces in C!

Re:C (Cbang) - A system oriented programming language by simias on Wednesday May 09, 2012 @10:35AM (#3948752)
Indeed, however this first blog post doesn't tell us much about the language itself. The couple examples seem a bit... anecdotal.

I'd also like to point out that setting individual bits in an integer is not usually atomic. So the "syntactic sugar" here could be pretty error-prone (and I can't say it was very high on my list of "features I wish C had").

Re:C (Cbang) - A system oriented programming language by cmdkeen on Wednesday May 09, 2012 @10:28AM (#3948717)
But they've identified this as for systems based programming where you don't have any guarantee of stdint.h holding true (POSIX compliance). Their implementation is much more flexible. Albeit slightly reinventing the wheel.
Re:C (Cbang) - A system oriented programming language by alexchamberlain on Wednesday May 09, 2012 @10:33AM (#3948742)
I can see what you mean, but stdint.h is just a bunch of typedefs stardardising the naming scheme. It doesn't take much work to sort it out.
Re:C (Cbang) - A system oriented programming language by simias on Wednesday May 09, 2012 @10:37AM (#3948764)
Indeed, linux uses u32 and friends for instance. It's really not much of a problem in practice (kernels are by definition very hardware dependent anyway...)
Re:C (Cbang) - A system oriented programming language by cube13 on Wednesday May 09, 2012 @11:05AM (#3948886)
If you're doing systems level programming, you shouldn't be counting on anything being portable anyway. Reimplementing it is worthless for projects are on a single OS. If you're implementing the OS, then these decisions need to be made anyway, independent of the language.

You should be coding to(or with) the OS you're working on. If you're doing multiplatform stuff, then #defines with a naming scheme work, and are already the standard practice.