7 ms·
I'm an intermediate scheme programmer (experienced in C, Python, etc), and one thing I really didn't like about R6RS in general, and Racket in particular, is th
by fizixer 10y ago
I'm an intermediate scheme programmer (experienced in C, Python, etc), and one thing I really didn't like about R6RS in general, and Racket in particular, is the amount of bloat.
I'm a staunch minimalist and one of the things that appealed to me learning scheme for the first time was the minimalism of the language syntax. Then I started learning about Racket (and Clojure) and realized they give you the kitchen sink of syntax and language features and take all the minimalism away.
So my question is: How much extra effort would it be if I wanted to do whatever is described in this book in an R7RS implementation, like Chibi, instead of R6RS?
- sigzero 10y agohttps://github.com/lexi-lambda/racket-r7rs https://github.com/lexi-lambda/racket-r7rs Racket can be used in many ways.
- mballantyne 10y agoFirst, a small defense of Racket. Racket has a small core relative to its apparent size; most of the bloat is in optional library code. All the fancy special forms for pattern matching, classes, contracts, etc are just optional macros from the libraries, and everything eventually expands down into this rather small core language: https://docs.racket-lang.org/reference/syntax-model.html#%28part._fully-expanded%29 https://docs.racket-lang.org/reference/syntax-model.html#%28... The default `#lang racket` is a big batteries-included language including all that stuff, but the core `#lang racket/base` isn't very big. I always program in `#lang racket/base` and pull in just the libraries I need. For me the most beautiful part of Racket is this juxtaposition of a small core language and a big extended language implemented through a standard library of macros. You can also install a distribution of Racket that leaves out bloat like DrRacket, Slideshow and the teaching language packages from the release variants page: https://download.racket-lang.org/releases/6.8/ https://download.racket-lang.org/releases/6.8/ As to your question, Beautiful Racket appears largely a guide to the language extensibility features that are specific to Racket and not shared by other Scheme systems like Chibi. Things like the `#lang` system, lexer library, and syntax highlighting integration in DrRacket. I imagine you'd get the most benefit out of it by working through it in Racket, and subsequently thinking about how to apply the ideas in other systems like Chibi.