Live data from Hacker News

Dear sir, you have built a compiler

rachitnigam.com

51–60 of 177 posts

Re: Dear sir, you have built a compiler

#51

Earlier quoted context omitted.

Racket is often heralded as the "programming language programming language" and comes with tons of features to build full blown languages: https://racket-lang.org/ The most complete language/ecosystem that really showcases Racket's capabilities is Rosette IMO: https://github.com/emina/rosette/

Also worth noting that language that runs this very website was implemented in Racket.

I thought that was Arc?

Re: Dear sir, you have built a compiler

#52

Earlier quoted context omitted.

Racket is often heralded as the "programming language programming language" and comes with tons of features to build full blown languages: https://racket-lang.org/ The most complete language/ecosystem that really showcases Racket's capabilities is Rosette IMO: https://github.com/emina/rosette/

Also worth noting that language that runs this very website was implemented in Racket.

Hacker News runs on a language that runs on Racket? Which language is that?

Re: Dear sir, you have built a compiler

#53
post #31

I feel like you can apply the same sentiment to many of the "big scary things" in programming. Things that you don't want to build (as far as "common engineering wisdom" is to be believed): - a compiler - a programming language (not sure that there is a difference to compiler as stated in the article) - a database (query engine) - a CMS - a ERP But sometimes you actually _do_ want to build that (even if every alarm b…

Yes. Another way to put it is: engineering should be focused on what's needed more than what the Right People On The Internet Say.

Additionally, the dirty secret of all those things is they make orders of magnitude more sense to dig into and learn vs the innumerable arcane errors require Googling to fix (obscure Webpack errors, CSS hackery, etc). Your learning accumulates over time.

Re: Dear sir, you have built a compiler

#54

Earlier quoted context omitted.

Just use flex / bison?

I've always found ANTLR to be more intuitive and maintainable than the flex/bison combination. And the learning curve is gentler.

And the tooling is better. I always found it hard to find working examples with bison.

Re: Dear sir, you have built a compiler

#55
post #31

I feel like you can apply the same sentiment to many of the "big scary things" in programming. Things that you don't want to build (as far as "common engineering wisdom" is to be believed): - a compiler - a programming language (not sure that there is a difference to compiler as stated in the article) - a database (query engine) - a CMS - a ERP But sometimes you actually _do_ want to build that (even if every alarm b…

You wanna get crazy?

When you hit:

- a ERP

You start to build all the others!

(This is where I'm now!)

Re: Dear sir, you have built a compiler

#56
This reminds me of a great post about the typical software evolution going from hard coded values, through configuration and rules engines to a DSL, only to be back where you started.

I have seen it happen on multiple projects, it’s hard to spot it at the time as all the changes seem sensible but hindsight is a wonderful thing

http://mikehadlow.blogspot.com/2012/05/configuration-complex...

Re: Dear sir, you have built a compiler

#57
post #31

I feel like you can apply the same sentiment to many of the "big scary things" in programming. Things that you don't want to build (as far as "common engineering wisdom" is to be believed): - a compiler - a programming language (not sure that there is a difference to compiler as stated in the article) - a database (query engine) - a CMS - a ERP But sometimes you actually _do_ want to build that (even if every alarm b…

IMHO "programming language" would refer specifically to the grammar, type system, semantics, keywords, etc. and "compiler" would refer to the implementation that takes something written in that representation and outputs some type of executable. A pedantic distinction but probably a useful one, especially given how some languages have multiple implementations of their standard.

The Programming Languages course I took in college had us implement a toy subset of Ruby targeting the Lua VM. Easily the most interesting and useful class that I had the pleasure of experiencing; it completely changed how I think about languages. I think everybody should have exposure to the basic principles of compilers like syntax trees, flow analysis, calling conventions, and so forth (if not necessarily the more complicated stuff like operational semantics).

Re: Dear sir, you have built a compiler

#60
post #31

I feel like you can apply the same sentiment to many of the "big scary things" in programming. Things that you don't want to build (as far as "common engineering wisdom" is to be believed): - a compiler - a programming language (not sure that there is a difference to compiler as stated in the article) - a database (query engine) - a CMS - a ERP But sometimes you actually _do_ want to build that (even if every alarm b…

Any tutorials on building the last one? (Beyond basic Rails style CRUD) How do you clone SAP in a weekend?
Post reply on HN