4 ms·
guile for embedding works really nicely.
by codemac 6y ago
guile for embedding works really nicely.
- outworlder 6y agoSorry, I keep forgetting about Guile. That thing needs more love indeed.
- grugagag 6y agoAs a newbie im getting a bit confused. What is the difference between guile and chicken scheme? There's also chez. Im even more confused
- deleted 6y ago[deleted]
- outworlder 6y agoThese are different implementations. The language spec they follow is slightly different so they are not completely compatible (although I've been able to use some OpenGL-ES Racket code with no modifications in Chicken by using macros). Where they will differ the most is things like the packaging system (if they have packages, not all Scheme implementations will), as well as their main use-case. If you are interested, just pick one and start to learn Scheme, using any implementation. Their differences will become apparent quickly.
- grugagag 6y agoThank you. Quite a few options out there in terms of LISPS and a beginner like me can be quite confused. I started looking at SBCL, Chicken Scheme and Racket and since I'm a newbie I'll stick with racket for the learning phase. I seem to like more the uniformity of Scheme over the cl for example. Do people usually specialize in one or the other or use them interchangeably depending on libraries and such? Another slight barrier has been learning Emacs and that's another reason I chose racket. I like what Emacs is capable but I most likely revisit later.
- minerjoe 6y agoRacket can be a good first choice. I would nudge you, if I may, and if the lisp glove fits, into taking the deep dive into emacs + evil (optional) + paredit + SLIME/SLY + SBCL + Quicklisp There are fully configured starting setups out there for a quick start. That's basically the closest thing nowadays you'll get to experience the interactive power of the ol' Lisp Machines. That said, you might not always need such large runtimes and other lisps can fit the bill. For example, I usually program in CL (with C FFI) for most projects, but for embedding lisps into existing C programs, Guile can be a joy. Once I was programming servo motor controllers that offered C as one of the programming languages, and I embedded a single C file that gave me a tiny little scheme interpreter and I was then able to prototype motor control algorithms and setting in way less time than before. It's just a game changer for learning about a system when you can get a REPL on it and start rapidly digging and experimenting.
- grugagag 6y agoThanks. I tried emacs+slime+quicklisp on SBCL and it looks interesting but the learning curve is insane, for now I just want to learn some scheme and take it from there. Racket has some interesting libraries to tot with so Im really excited.
- Jtsummers 6y agoThey're each different implementations of Scheme, sometimes with different design goals (like embedding or scripting or for standalone programs). Scheme is a pretty simple language (in comparison to many others) and relatively small. There are also several versions (not just implementations). Common ones out there now are R5RS, R6RS (it was considered "big" and was somewhat unpopular), and R7RS. Consequently, different implementations are also conforming to different versions of the spec. Really, if you're wanting to learn Scheme, just pick one and run with it. For learning purposes they're mostly equivalent if you stick to the more popular ones, but be aware of your learning material and the version of Scheme that they're using. If you're familiar with other programming languages, it's somewhat like the relationship between different compilers. Though usually they adhere a bit more strictly to the same standards. Since Scheme is such a small language, there's more room for differences between implementations. This mostly doesn't affect you as a learner (most learning materials focus on the core parts of the language which all implementations should be consistent on).
- grugagag 6y agoThank a lot, I decided to give Racket a go. It has a fancy IDE and is battery included
- Jtsummers 6y agoCool. Racket's a great option, and it's really a multi-lingual environment. Technically not Scheme anymore, but compatible with it in most ways. So any learning material for Scheme will still apply, and you can select different Scheme versions within Racket if the Racket language itself is incompatible with whatever book or similar you're using.
- cycloptic 6y agoThere is a basic explanation that was written by the guile maintainer in 2013: https://www.wingolog.org/archives/2013/01/07/an-opinionated-guide-to-scheme-implementations https://www.wingolog.org/archives/2013/01/07/an-opinionated-...