7 ms·
Is Crystal still a thing? I thought it sought to keep Ruby ease but statically for speed and to reduce bugs?
by exabrial 8y ago
Is Crystal still a thing? I thought it sought to keep Ruby ease but statically for speed and to reduce bugs?
- anthonybullard 8y agoDefinitely still a thing, but development looks like it's slowed a bit. Maybe the Manas team is overwhelmed? 550 open issues and 130 open PRs. Nice language though, hope things improve!
- everdev 8y agoYes, I've enjoyed using it and there are several well written frameworks like Kemal, Amber and Lucky for apps. And it's really useful for CLIs and APIs.
- qop 8y agoCrystal is progressing well, but they don't have the resources of a lab full of incredible engineers thrown at it. It's definitely a threat though. The Amber Framework is very familiar to people who know Phoenix or Rails. Personally, coming from Ruby, Crystal has a slightly steeper learning curve. However, I feel that magic spark deep down now that I've spent more time with it and I'm more aware of what inference can do and how to use it for my benefit. Little safety things that seem irritating at first, but then you put the pieces together and understand them a bit more. T | Nil is a culprit here. It seems obnoxious, but then you realize, I can just chain methods in a case statement, I don't have to check for nil over and over, just in the topmost part of whatever code it is. It's not how I normally think, and my instinct was wrong based on my initial understanding, but now I'm much more comfortable with it. As for tooling, Crystal is rather weak. This too will come with time.
- vinceguidry 8y agoCrystal is a completely different language with a different architecture and object model that only superficially looks like Ruby. Porting code from Ruby to Crystal is somewhat easier than, say, porting the same code to Python, but is still an act of porting. You can't use any kind of automated drop-in process to rewrite Ruby code to Crystal. They're just too different. A good type system for Ruby is very much needed. Matz himself has stated that a type system is very much on the horizon for Ruby. Can't wait.
- qop 8y agoWith Ruby getting an AST, and potentially a type system in the future, I think that ruby 3 could lend itself to bring transpiled to crystal relatively easily, depending on exactly how much type information there is, how difficult / possible it is to correlate that with the AST. Scala 3 is doing the typed AST thing, so hell, why not?
- vinceguidry 8y agoSyntax is only the first obstacle. You also have the object model and the standard library to deal with as well.
- Kalium 8y agoYou're absolutely right! Any Turing-complete language can be transpiled to any other. That said, you can't always expect sensible or human-brain-friendly results if you're moving between two languages that work very different.
- workinthehead 8y agoWhy must you keep telling people "You're absolutely right!" It seems insincere and condescending at best. If you really think you know better than the person you're responding to, use evidence and logic, not cheap conversational ploys.
- Kalium 8y agoI do need to mix up the verbiage more. In practical terms, people respond much better to having their egos stroked than they do to being told they're wrong. Evidence and logic work much better when someone doesn't feel like their ego is at stake. Telling someone they're right before pointing out that they could be more right is one way to do this. Telling people that they're wrong is more likely to provoke a defensive reaction and a closed mind than it is genuine thoughtfulness and consideration. We've all seen people refuse logic, reason, and evidence because they feel personally attacked, I suspect. This is a lesson I gleaned from the (in)famous "How To Make Friends And Influence People". It's not wrong, it's just cynical. So of course it's insincere. Human interaction is greased with little insincerities. It's how we deal with egos.
- Willamin 8y agoIf larger companies (eg. Stripe) would put more effort into improving Crystal instead of improving Ruby, Crystal would absolutely blow Ruby out of the water. Instead we get improvements to Ruby because larger companies have larger codebases and don't want to refactor everything all at once. They'd rather slowly add type annotations to their Ruby codebase until eventually it's all done. I get it, it's better from a business perspective short term. In the long term, Crystal would be able to run at least hundreds of times faster than Ruby.
- pejrich 8y agoThere's absolutely no chance that a company like Stripe would spend resources improving a language like Crystal, or even think about porting their current code base to it. If porting was what they wanted to do, Crystal would only be slightly higher than Ancient Greek on their list of potential languages. Not saying I don't like Crystal, but it makes ZERO business sense for Stripe, and they are after all a business, not a programming language improvement charity.