Live data from Hacker News

Beautiful Racket

beautifulracket.com

11–20 of 55 posts

Re: Beautiful Racket

#11
post #4

This looks like a very well-written, easy introduction to making simple, dynamic programming languages (not surprising given the author's writing background). But everyone writes about how to build these kinds of basic Forths, or Lisps, or reverse polish notation calculators. To be honest, once you've learned the basic technique, writing a toy dynamic language interpreter is pretty easy. Even adding a toy JIT isn't v…

These should get you started. The last two are by Simon Peyton Jones, one of the creators of Haskell.

One Hour ML https://vimeo.com/64593770

Algorithm W Step by Step http://catamorph.de/documents/AlgorithmW.pdf

Implementing functional languages http://research.microsoft.com/en-us/um/people/simonpj/Papers...

The Implementation of Functional Programming Languages http://research.microsoft.com/en-us/um/people/simonpj/Papers...

Re: Beautiful Racket

#12
post #4

This looks like a very well-written, easy introduction to making simple, dynamic programming languages (not surprising given the author's writing background). But everyone writes about how to build these kinds of basic Forths, or Lisps, or reverse polish notation calculators. To be honest, once you've learned the basic technique, writing a toy dynamic language interpreter is pretty easy. Even adding a toy JIT isn't v…

These should get you started. The last two are by Simon Peyton Jones, one of the creators of Haskell. One Hour ML https://vimeo.com/64593770 Algorithm W Step by Step http://catamorph.de/documents/AlgorithmW.pdf Implementing functional languages http://research.microsoft.com/en-us/um/people/simonpj/Papers... The Implementation of Functional Programming Languages http://research.microsoft.com/en-us/um/people/simonpj/Pa…

Oh, those are great, thanks. Not big on videos, but the Algo W pdf is great, and the last book is exactly what I need, and looks to answer some of the questions I'm running into doing this on my own (3rd one looks a little advanced for me at this point, maybe after I get through the Peyton Jones textbook).

Re: Beautiful Racket

#13
One of my favorite classes in college was designed around building a C-like language interpreter (not compiler, I know, but the syntax was C-like) in Racket. It was a fantastic, eye-opening experience.

However, DrRacket the IDE was a huge pain for me. I often felt that what the language offered in power and sophistication, its development environment lacked.

Re: Beautiful Racket

#14
post #4

This looks like a very well-written, easy introduction to making simple, dynamic programming languages (not surprising given the author's writing background). But everyone writes about how to build these kinds of basic Forths, or Lisps, or reverse polish notation calculators. To be honest, once you've learned the basic technique, writing a toy dynamic language interpreter is pretty easy. Even adding a toy JIT isn't v…

There was a great textbook by Sam Kamin around 1990 ( http://loome.cs.uiuc.edu/kamin/pubs.html ). I think that might help.

Thanks, looks like a very good book, but looks to focus mainly on dynamic languages, no?

Re: Beautiful Racket

#15

One of my favorite classes in college was designed around building a C-like language interpreter (not compiler, I know, but the syntax was C-like) in Racket. It was a fantastic, eye-opening experience. However, DrRacket the IDE was a huge pain for me. I often felt that what the language offered in power and sophistication, its development environment lacked.

You can run racket as a console application and it can be run through emacs or standalone with any editor.

Re: Beautiful Racket

#16

One of my favorite classes in college was designed around building a C-like language interpreter (not compiler, I know, but the syntax was C-like) in Racket. It was a fantastic, eye-opening experience. However, DrRacket the IDE was a huge pain for me. I often felt that what the language offered in power and sophistication, its development environment lacked.

You can run racket as a console application and it can be run through emacs or standalone with any editor.

For sure -- but the class was taught using the IDE and it's what everybody ended up using. I felt kinda stuck with it.

Re: Beautiful Racket

#17
post #4

This looks like a very well-written, easy introduction to making simple, dynamic programming languages (not surprising given the author's writing background). But everyone writes about how to build these kinds of basic Forths, or Lisps, or reverse polish notation calculators. To be honest, once you've learned the basic technique, writing a toy dynamic language interpreter is pretty easy. Even adding a toy JIT isn't v…

Pierce's Types and Programming Languages ( https://www.cis.upenn.edu/~bcpierce/tapl/ ) is great - I'm working throught it now. Its goes through both untyped and statically typed languages. It also goes into how to implement these things in OCaml.

Re: Beautiful Racket

#18
post #10
post #6

Earlier quoted context omitted.

Are you looking for general references on implementing type checkers and ML-like languages? Or how to implement those as languages in Racket specifically?

Either or any would be great, particularly if they're online and not books (although I'd buy a good book that covered those topics in depth). Particularly an approachable intro to Hindley-Milner and building a toy/mini-ML, and type checking in general. All the better if it's in Racket, or some ML. Actually, do you know of any examples of ML-type languages, or any statically-typed languages, that are written in Racket…

It looks like Pyret was first written in Racket. I think it's optionally typed, though.

https://github.com/brownplt/pyret-lang-resugarer

Re: Beautiful Racket

#19
post #5

> If a datum sounds like a syn­tax object, that’s no coin­ci­dence — a syn­tax object is just a datum with some extra infor­ma­tion attached. The #' pre­fix nota­tion we used for a syn­tax object now con­nects log­i­cally: we can think of the # as rep­re­sent­ing the extra info that gets attached to the datum This is not clear, can someone explain please?

Not sure which part isn't clear. First, syntax objects are data, but with extra information, such as binding information, source location, etc. Second, the #' form (written out it's called `syntax`) is similar to the ' form (written out as `quote`). But the first one includes the extra information to make a syntax object. Also, it has an extra character, which the chapter points out can be seen as going along with th…

This is why I wish I could ask comments about books without going to Stack Overflow. Is there a publishing system that allows you to put up a work as it is being produced and solicit input from people on what they find unclear?

Re: Beautiful Racket

#20
post #5

Earlier quoted context omitted.

Not sure which part isn't clear. First, syntax objects are data, but with extra information, such as binding information, source location, etc. Second, the #' form (written out it's called `syntax`) is similar to the ' form (written out as `quote`). But the first one includes the extra information to make a syntax object. Also, it has an extra character, which the chapter points out can be seen as going along with th…

This is why I wish I could ask comments about books without going to Stack Overflow. Is there a publishing system that allows you to put up a work as it is being produced and solicit input from people on what they find unclear?

Gitbook. I've used it for two small (unpublished) books.

https://www.gitbook.com/

E:

I may have misparsed your question, upon re-reading it and had an overly liberal understanding of "solicit feedback". Apologies in advance if my answer isn't quite up the alley you were looking for.

Post reply on HN