Live data from Hacker News

The Crystal Programming Language

crystal-lang.org

81–90 of 116 posts

Re: The Crystal Programming Language

#81
Crystal is reaching its 10th anniversary (of the first commit).

To celebrate that there is going to be a live event next Monday: https://forum.crystal-lang.org/t/10-years-of-crystal-celebra...

We're exploring the history and future of the language with past and current core contributors as well as industry guests.

Re: The Crystal Programming Language

#82
post #67

Earlier quoted context omitted.

> Personally, I thought the muddled Proc, block, and lambda situation a mess Why not use one (probably just block) for everything? Coming from ruby 10 years ago.

Blocks can't be stored in variables.

Yes, I don't store them in variables, but I can expand them in generators and yield them. To me, that is much more useful than storing them.

Re: The Crystal Programming Language

#83

Earlier quoted context omitted.

Probably because of the Ruby inspired syntax which just brings joy. Hopefully the ecosystem can grow and partially catch up as well

i've seen that said so many times, and fail to understand why Ruby syntax brings joy. Personally, I thought the muddled Proc, block, and lambda situation a mess, coming from Scheme 30 years ago to Ruby 20 years ago.

That's quite a minor nitpick on an entire language that's been around for over 25 years.

Re: The Crystal Programming Language

#84
post #55

Huge props for the Crystal lang team. Crystal powers 90% of the Kagi search backend (reminder being Python). Highlights are great performance and concurency handling. Biggest downsides at this moment are compilation speed (does not take advantage of multi CPU cores) and debugging tools. Overall our experience has been fantastic (we adopted it while still in beta) and the pace the language is developing is great.

What do you mean by great concurrency? Last I checked multithreading was still hidden behind an experimental compiler flag, which turns me off a bit...

I did a small comparison of implementing pipeline concurrency in Go and Crystal:

https://rillabs.com/posts/crystal-concurrency-easier-syntax-...

Crystal pretty much provides the same (great) concurrency functionality with light-weight threads and channels etc, but with a cleaner syntax and in my experience less gotchas around closing channels in the wrong place and order etc.

The main downsides compared to Go I've seen is:

- (As mentioned) Compile times

- Far less compelling cross-compilation story

Re: The Crystal Programming Language

#85

Earlier quoted context omitted.

Probably because of the Ruby inspired syntax which just brings joy. Hopefully the ecosystem can grow and partially catch up as well

i've seen that said so many times, and fail to understand why Ruby syntax brings joy. Personally, I thought the muddled Proc, block, and lambda situation a mess, coming from Scheme 30 years ago to Ruby 20 years ago.

When I saw it, I felt the same way (also using Scheme a lot) and I still feel it is messy. However, what I think might be the reason for it, is that it is difficult to store a lambda in Scheme including its whole environment in an object and send that over the wire somewhere else, on a different machine to run. Perhaps distinguishing between Proc, block and lambda gives Ruby a possibility to treat one of them specially, so that it can do these things easily?

Re: The Crystal Programming Language

#86

Huge props for the Crystal lang team. Crystal powers 90% of the Kagi search backend (reminder being Python). Highlights are great performance and concurency handling. Biggest downsides at this moment are compilation speed (does not take advantage of multi CPU cores) and debugging tools. Overall our experience has been fantastic (we adopted it while still in beta) and the pace the language is developing is great.

Just want to say I am very happy with Kagi. I've been a paying subscriber since there was an announcement here a few months ago. The results are typically very good, the speed is unreal, and features like lenses and personalized results are so awesome. It's so nice not having search results filled with Stack Overflow spam sites, and if anything slips through I can block it.

Re: The Crystal Programming Language

#87
post #54

Earlier quoted context omitted.

there is a runtime. its just baked into the final executable. you can't have garbage collection without one.

Everything has a runtime nowadays. Even C, even if it isn't all that large (including for example the memory structures necessary to keep malloc and free working).

I think that’s too expansive of a definition of “runtime.” The context required by C and Rust programs is generally internal, meaning that interacting with the dynamic allocator doesn’t require the programmer to be aware of the implementation’s invariants. This is in contrast to a managed language like Java, where using a managed object from C via JNI requires coordination with the runtime (which in turn preserves the invariants).

Re: The Crystal Programming Language

#88
post #61

I'm a Ruby guy and I tried Crystal for about 2 years and absolutely loved it but then had to give up for the following reasons: 1. Too slow to compile (the whole program + the entire stdlib is built everytime you build!). No incremental compilation available. 2. No language server (apparently it's just impossible due to the way the language works). Tbh, I'd be happy with just "Go to definition" but alas, no-can-do! 3…

> 3. Obscure error messages (macros are to blame here) I feel like this is a bit strongly influenced by the macro experience. Macros are an advanced and powerful feature and naturally more complex to debug. In general, Crystal's error messages are often praised for their clarity and helpfulness (especially compared to dynamically typed languages, of course). > 4. Weak HTTP server implementation -- making things such…

> Windows support is pretty stable and almost complete by now.

This isn't really a genuine statement. Currently Crystal Requires a full installation of Visual Studio on Windows:

https://github.com/crystal-lang/crystal/issues/6170

Re: The Crystal Programming Language

#89
post #12

I used Crystal to create a web application a 2-3 years ago. It is running great without any problems. There are not that many users (only about 300-400) at any time. Anyhow, I did not touch the application in the last two years, and did not use Crystal in the last two years for anything else. I used Rust to write some simple personal CLI apps, which was fun but also hard. For some reason, couple of days back I return…

Probably because of the Ruby inspired syntax which just brings joy. Hopefully the ecosystem can grow and partially catch up as well

Same argument that I keep on having with people who like 1. gray and darker gray buildings of a tree-less megacity beautiful, with a dash of color vs 2. those who find small cities/villages mixed with art, trees & colourfully dressed people beautiful.

Re: The Crystal Programming Language

#90
post #54

Earlier quoted context omitted.

Everything has a runtime nowadays. Even C, even if it isn't all that large (including for example the memory structures necessary to keep malloc and free working).

I think that’s too expansive of a definition of “runtime.” The context required by C and Rust programs is generally internal, meaning that interacting with the dynamic allocator doesn’t require the programmer to be aware of the implementation’s invariants. This is in contrast to a managed language like Java, where using a managed object from C via JNI requires coordination with the runtime (which in turn preserves th…

But you have to know that as well for C - there are for example several Linux system calls you really should not call manually because that would fuck up the internal state in LibC. Yes, the runtime is really small, comparatively speaking, but it is still a runtime.
Post reply on HN