Jump to content
  • Advertisement
Sign in to follow this  
programwizard

How do I make my own programming language?

This topic is 4833 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I know that's a very big question to ask, but does anyone know of some websites or books that would give you at least the basics of writing your own language/compiler?

Share this post


Link to post
Share on other sites
Advertisement
If your interested you can follow this website I have put up for specifications for a new language. CodeBASIC . Also looking for input and feedback, so your more than welcome to post questions.

Share this post


Link to post
Share on other sites
Depends on what exactly you mean.

Making a programming language is easy. Just sit down with a piece of paper, and write a few rules down for the language. Then that's a (probably very ambiguous, and not very useful) language specification.

If you want to write a compiler or interpreter for the language, it's a lot more complex. ;)
But then it's basically the same as writing those for an existing language.

Share this post


Link to post
Share on other sites
Guest Anonymous Poster
The "Dragon Book" is very good. It's actual name is "Compilers: Principles, Techniques, and Tools", by Alfred V. Aho, Ravi Sethi and Jeffrey D. Ullman. It may be a bit dated in some areas, but it's still the canonical reference book for anyone wanting to create a compiler (or interpreter).

Share this post


Link to post
Share on other sites
I'm currently taking translators (which is basically introduction to writing compilers). And it is certainly not for the faint of heart, but it is a fantastic thing to understand. Knowing things like parse trees and syntax directed translation help you think like your compiler, and you can more readily understand why things are implemented the way they are in todays languages. I agree with the previous posts suggesting Flex/Bison (some times refered to as lex/yacc which were very similar beasts from way back when). The standard as far as books on compilers is concerned is still "Compilers: Principles, Tools, and Techniques" by Alfred V Aho, Et. Al. (ISBN 0201100886), although it was written in 1986. Best of luck in your studies.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!