I wrote what could be called a "Multiboot barebones" - a kout global object used by a main() to print the values from the multiboot data structure, nothing more.Twitch wrote:And if so how did it change the design of the kernel aposed to a C kernel?
The beauty of "cout << whatever" was a clear winner in my book, because you didn't have to do any format string parsing or whatnot to make it work, and extending kout with another data type was dead simple, too. I strongly believe similar benefits can be had in many other parts of the kernel.
Another strong point is that, with C++, it becomes quite natural to keep data structure definitions and the code handling those structures together, something that requires a conscious effort to do in C.
And in the end, any good C code I have seen so far is effectively object oriented anyway, so why not use a language that supports this with additional syntactic suggar that doesn't cost you anything (if used correctly)?
Standard disclaimer, your mileage might vary.