Programing Languages
Programing Languages
Why is it almost every programming language for linux must be compiled using a c++ compiler?
No, that's not what he means.
e.g. Python itself (not code written in the Python language) is written in C and compiled with ./configure; make; make install
e.g. Python itself (not code written in the Python language) is written in C and compiled with ./configure; make; make install
Do you know a good gtkdialog program? Please post a link here
Classic Puppy quotes
ROOT FOREVER
GTK2 FOREVER
Classic Puppy quotes
ROOT FOREVER
GTK2 FOREVER
Larry,
How else would you expect to build them?
How else would you expect to build them?
Do you know a good gtkdialog program? Please post a link here
Classic Puppy quotes
ROOT FOREVER
GTK2 FOREVER
Classic Puppy quotes
ROOT FOREVER
GTK2 FOREVER
Isn't C++ just a pre-processor for C anyway? That is, the pre-processor accepts C++ and rewrites it as C source, which is then further pre-processed into assembly source, then ultimately assembled into binary for the target CPU. Many "compilers" allow you to stop and examine the code generated at each stage. Using the pre-process technique, it seems to me nearly any language could be designed who's output would be C source code.
[b]Hasten Slowly![/b]
- Pizzasgood
- Posts: 6183
- Joined: Wed 04 May 2005, 20:28
- Location: Knoxville, TN, USA
Compiled languages need a compiler to compile them, and interpreted languages need an interpreter to interpret them. Those programs have to come from somewhere. Once you have a compiler for the language, you can of course write a new compiler for the language using the language itself. But before you reach that point you have a chicken and egg scenario. The simplest solution is to first write a compiler for the language in a different language that is already set up. The typical choice is C because it's pretty much the most common language you're going to find on nearly any platform. You write a compiler for your language using C, then you write another compiler for the language, this time using the language itself, and compile it using the compiler that was written in C. Now you are free from needing C, on this platform. However, if you want to make the language availible on another platform (like Mac or Windows, or an ARM processor, etc.) you'd have to either bring back the C version of the compiler so that it can be recompiled natively on the destination platform, or else implement a cross-compiler so that you can compile a compiler ahead of time.
If any of that is confusing, sorry. I should have gone to sleep a while ago.
If any of that is confusing, sorry. I should have gone to sleep a while ago.
[size=75]Between depriving a man of one hour from his life and depriving him of his life there exists only a difference of degree. --Muad'Dib[/size]
[img]http://www.browserloadofcoolness.com/sig.png[/img]
[img]http://www.browserloadofcoolness.com/sig.png[/img]