3 ms·
The docs are not available at that URL. It looks like the https is a different server. They seem to be here: http://c2lang.org/site/ http://c2lang.org/site/
by J_Darnley 10y ago
The docs are not available at that URL. It looks like the https is a different server. They seem to be here: http://c2lang.org/site/ http://c2lang.org/site/
[edits...]
I'm glad it has explicit integer sizes. I use C99 standard types often. I don't have much of an opinion on the explicit bool type although I hope it has a defined size.
I'm surprised it allows fall-through in a switch statement. I thought people hated C in that you needed a break keyword to prevent it.
It is interesting that its compiler is also the build system but I see that being a problem if you need to mix languages. For example: I have a Lua script I want to embed into my code. Doing this is simple with make and hard with every other build system.
Windows/Cygwin support means I will look at building this.
- magnusi 10y agoOh I am sorry, I made a stupid typo.
- magnusi 10y agoYes, I really like explicit integer sizes too and yes. C2 is trying to be as close to C as possible, with just improving what is "bad" or cumbersome, so some things like the fall-through are still there. You can certainly mix languages, since C2C (the compiler) allows single-file compilation, although a bit cumbersome, with the -f parameter and currently, it works like this: 1. Find (recursive searching upwards in directory tree) & Read a recipe file (a file for the build system) 2. Either start building all targets or just some, depending on the command-line arguments 3. Build the targets. Output is C (basically complete) or LLVM IR bytecode (like 25% complete). 4. Write a makefile for said C files 5. Compile with default C compiler so mixing languages works with a little hacking. I am the author of the Windows/Cygwin support/port, so in case anything doesn't work (especially since the compilation of LLVM is often a horror in Cygwin), let me know and I will see what I can do.