compiler help.

are there anny compilers that work for all programming languages or maybe just these programming languages?

java/javascript,lua,c++ it has to work for all 3 of these cause me and my friend are working on a project but he only knows javascript and i know lua,c++

If there isn't then how do i make my own compiler?
One compiler compiles one language. Why would you what it differently? What you really need is to find how to call lua and javascript scripts from c++ code.
Writing a compiler is a tremendously complex task.
then how do i call them plz help and thnx
ummmm you can't compile javascript... im not sure about lua
as to calling here is a link: http://csl.sublevel3.org/lua/
also a computer can't understand c++ so what a compiler does is turn it into machine language (which is composed solely of 0's and 1's) you can't have just one compiler for all languages because their commands and formats are compiled differently. You can group together compilers though.

edit: lua can't be compiled either. That is because they are scripting languages not programming language
Last edited on
Like the others said, javascript and lua don't need to be compiled. So, the only compiler you need is for c++. Not sure what you are doing mixing those three languages, though (specially javascript with the other two). Unless you mean mix them in a single program, which, as far as I know, can't be done. As Aramil of Elixia stated, lua can be integrated with C (and C++ consequently).

Also, lua chunks can be compiled beforehand to increase performance if you call it many times.
yeah i no for a fact lua can be embedded in c++ (that is what world of warcraft is) but im pretty sure that java script is solely for html
What languages did world of warcraft use i heard alot but i'm probly wrong btw i'm working on a multiplayer cardgame. but he's made tons of games with java or javascript i wonder how?
c++ w/ lua
You can call lua or javascript code from C++.
You can download lua libraries from lua's site. The follow http://csl.sublevel3.org/lua/ or something like that.
To run javascript, try http://code.google.com/p/v8/
Note that I haven't done this, so I can't help much.
Topic archived. No new replies allowed.