Messages in this thread | | | Date | Mon, 3 Dec 2007 11:53:47 -0500 | Subject | Re: Kernel Development & Objective-C | From | (Lennart Sorensen) |
| |
On Sat, Dec 01, 2007 at 09:59:31PM +0200, Avi Kivity wrote: > C also requires a (very minimal) runtime. And I don't see how having a > runtime disqualifies a language from being usable in a kernel; the > runtime is just one more library, either supplied by the compiler or by > the kernel.
Well the majority of C syntax requires no runtime library. There are some system call like things that you often want that need a library (like malloc and such), but those aren't really part of C itself. Of course without malloc and printf and file i/o calls the program would probably be a bit boring. I have written some small C programs without a runtime, where the few things I needed where implemented in assembly and poked the hardware directly and called from the C program.
> Object orientation in C leaves much to be desired; see the huge number > of void pointers and container_of()s in the kernel.
As a programming language, C leaves much to be desired.
-- Len Sorensen
| |