PDA

View Full Version : Creating a programming language



incognito
10-03-2004, 09:44 AM
Well I am in deep ......Because my collegue professor, after a couple of lessons has decided to have us create a programming language. To tell you the truth I don't know where to start. I tried javacc, but I am not sure this is what I am looking for. Any uselfull links would be greatly appreciated. I mean there has to be a tool to aid you on this and to help you turn your file into an executable. It could be either in C/C++ or Java. Please guys help me out here. Thanks in advance.

Prelude
10-03-2004, 09:47 AM
Did your professor specify a compiled language? Why not just write an interpreter?

incognito
10-03-2004, 09:58 AM
He didn't really specify it, but I think he's was leanning towards an executable, that's what I've seen other students do before. But most of them use a utility that's available to Visual Basic, but I rather not use Visual Basic. His only requirement is to make it so it analyses at least 6 words.. He also started talking about, "Some of you will go really simple but others will go right ahead and just about make something that compiles C entirely". So this makes me think he doesn't want an interpreter. And he gave us two weeks. Which doesn't give me a lot of time, ya know with work and all.

curlious
10-03-2004, 10:03 AM
I think tools like yac, lex and bison will come in handy.

dayknight
10-03-2004, 10:14 AM
Did your professor specify a compiled language? Why not just write an interpreter?

double that.

since i think writting a compiler would be much more difficult than wriiting a interpreter for c++/c/java
combine all three, make it a basic oop language (more on the lines of psudocode)


it would be cool if i said:

start prog:

Func:

dis: something //display
do: 1+2 = sum
out: sum //output

Salem
10-03-2004, 10:14 AM
http://www.bloodshed.net/compilers/index.html#toolkits
Some theory, and some tools

incognito
10-03-2004, 10:21 AM
Thank you all. I am going to get on this right away.

okinrus
10-03-2004, 05:57 PM
Javacc is LL(1), so for most programming languages you will have retrofit your grammar. Flex and Bison are fairly easy to use.