One really cool question

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
StevX

One really cool question

Post by StevX »

- Hi

- In what programming language(s) was written Windows or Linux??? 8)

OK, that's all.

Good Bye.
StevX
Oxyd

Re:One really cool question

Post by Oxyd »

Linux is mostly written in C (and some parts in assembly, of course). It's open source - the kernel source comes usually with the distribution you get (search for package called kernel-source, or simillar, if you have an rpm-based Linux system).

Windows isn't open source, so I don't know, but it ought to be C, because it has C API for other applications. But I heard rumors, the API is just a wrapper for the actual C++ source...

Oxyd
User avatar
Brendan
Member
Member
Posts: 8561
Joined: Sat Jan 15, 2005 12:00 am
Location: At his keyboard!
Contact:

Re:One really cool question

Post by Brendan »

Hi,
Oxyd wrote: Windows isn't open source, so I don't know, but it ought to be C, because it has C API for other applications. But I heard rumors, the API is just a wrapper for the actual C++ source...
I don't know either, but AFAIK Windows API doesn't use the C calling convention, but instead uses the Pascal method. I doubt this implies it's written in Pascal though (most modern compilers support several calling conventions). Linux (for e.g.) uses software interrupt 0x80 and passes parameters in registers, even though it is written in C.

Besides, I think Windows is written in GW-BASIC ;D.


Cheers,

Brendan
For all things; perfection is, and will always remain, impossible to achieve in practice. However; by striving for perfection we create things that are as perfect as practically possible. Let the pursuit of perfection be our guide.
pini

Re:One really cool question

Post by pini »

<troll>
Windows might have been written in goto++ (http://www.sidoine.net/gpp/) :D
</troll>
User avatar
Colonel Kernel
Member
Member
Posts: 1437
Joined: Tue Oct 17, 2006 6:06 pm
Location: Vancouver, BC, Canada
Contact:

Re:One really cool question

Post by Colonel Kernel »

The NT kernel was written in C. Most of the ugly user-land libraries (COM, the shell, and other nastiness) are written in C++... sort of. I had the chance to chat with some MS guys and they call it (jokingly) "Microsoft C++", which is really to say they historically used C++ as a better C most of the time.

With the growing push behind .NET (and std C++ conformance) internally at MS in recent years, I'd imagine that real OO design methodologies are starting to gain some traction there, but I'm not sure if this extends to the teams who work on the OS itself.
Top three reasons why my OS project died:
  1. Too much overtime at work
  2. Got married
  3. My brain got stuck in an infinite loop while trying to design the memory manager
Don't let this happen to you!
Post Reply