3 ms·
I meant the packages of the stdlib, not community-made packages. A great example is the things I learned about the IO module and how it plays with the other mod
by Svenskunganka 10y ago
I meant the packages of the stdlib, not community-made packages. A great example is the things I learned about the IO module and how it plays with the other modules in the stdlib for Crystal that I could easily see a similarity in behavior and methods in the Go implementation, but not being able to fully understand before I had a go with Crystal.
The way they interact with different types, fibers and allocation on the stack vs heap, etc. Makes sense?
Edit: To give you an example of how friendly the Crystal lang & API documentation is to developers unfamilliar with the language, let's look at the Iterator: https://crystal-lang.org/api/0.18.7/Iterator.html https://crystal-lang.org/api/0.18.7/Iterator.html
It comes with a great "introduction" to what it is, what it does and gives an example of the advantages it has over the Enumerable. It also explains how you can implement your own Iterator.
We can also look at the IO module for Crystal and the io package for Go:
https://crystal-lang.org/api/0.18.7/IO.html https://crystal-lang.org/api/0.18.7/IO.html
https://golang.org/pkg/io/ https://golang.org/pkg/io/
From a beginners standpoint, you have to see that the Crystal documentation is way more friendlier.