C vc C++

Question about which tools to use, bugs, the best way to implement a function, etc should go here. Don't forget to see if your question is answered in the wiki first! When in doubt post here.
Post Reply
guest

C vc C++

Post by guest »

Hello,
I want to know what will make me write my OS in C or in C++
why some people use C and others C++ ?
By the way, in the both languages we will use ASM.
sfdgb

Re:C vc C++

Post by sfdgb »

you write it in html
User avatar
Pype.Clicker
Member
Member
Posts: 5964
Joined: Wed Oct 18, 2006 2:31 am
Location: In a galaxy, far, far away
Contact:

Re:C vc C++

Post by Pype.Clicker »

sfdgb wrote: you write it in html
oh! what a smart answer ...

Picking either C or C++ is merely a matter of taste, personnal experience, and how "fluent" you're in the language you pick ...
Schol-R-LEA

Re:C vc C++

Post by Schol-R-LEA »

RTFAQ, please.

What language you use is purely a matter of personal preference, provided that language you choose is suitable for low-level programming (that is, it isn't specific to an existing OS, and it requires little if any runtime support from a library or interpreter). C is the most commonly used language mainly because it is familiar to most OS developers, and there is a large body of literature available about OS development in it. C++ requires more runtime support, but certainly can be used.

Of course, as you pointed out yourself, no matter what languages you write parts of the OS in there are some parts which must be written in assembly. It is always possible to write the whole OS in assembly, but most programmers don't have the patience and skill to manage that. If you think you can manage it, however, you should feel free to try if you wish.

You may wish to consult the 'Language Design' threads in the General Programming message board. HTH.
guest

Re:C vc C++

Post by guest »

Thank you very much Schol-R-LEA and you Pype.Clicker but no thanks to sfdgb for his smart answer.
fxyj

Re:C vc C++

Post by fxyj »

ungreatful guests ..
AGI1122

Re:C vc C++

Post by AGI1122 »

Of course he isn't going to be greatfull, you didn't help out one bit. :P
Post Reply