4 ms·
I indeed really liked Ruby because of it's expresiveness, it being totally OO, the lovely readable and writeable syntax. But yeah, that was 20 years ago. These
by jurgenkesker 10mo ago
I indeed really liked Ruby because of it's expresiveness, it being totally OO, the lovely readable and writeable syntax.
But yeah, that was 20 years ago. These days I find Kotlin to be the perfect fit for my projects, because of the static typing and its ergonomic syntax. I just don't feel confident about Ruby projects when they start growing. But, I still love the language, although mostly for small things.
- zug_zug 10mo agoYeah. I was pretty neutral on ruby, until somewhere I worked some coworker put an @ on a variable relating to sessions and suddenly people started seeing each other's accounts. Now some people won't fault the language for that, but it feels like a footgun and I've noticed a trend that often the worst (I.e. most dangerous) gravitate toward languages with the fewest safeties in them (less type safety, no compile checks, no memory safety, little concurrency safety, less safety around shared state)
- jcheng 10mo agoWhy do you think this is worse than someone saying about Java: "some coworker put `this.` on a variable relating to sessions and suddenly people started seeing each other's accounts"? Because it's less obvious what "@" means rather than "this."? Edit: I forgot that Java has implicit `this`! That's so, so much worse!
- brightball 10mo agoI have been using Ruby for 13 years and only once have I seen anybody use an @ on a variable…and it was part of a distributed caching strategy for an ad randomizer.
- mono442 10mo agoThis can happen it every language. I have seen the same thing happen in a project written in Java when someone has wrongly set the bean scope.
- werdnapk 10mo agoI'm pretty sure you mean @@ on a variable and are not common in a Ruby project. @@ is a class variable and I can see that causing all sorts of problems with data across sessions.
- lern_too_spel 10mo agoHow about the fact that Ruby makes immutability difficult, and Hash does not copy keys on write and read? Almost every program uses a hash table, and Ruby makes them especially dangerous.
- Lio 10mo agoAt least we have new features for immutability as part of Ractors. e.g. Ractor.make_shareable(data)
- psychoslave 10mo agoNot totally though. Try `if.class` in IRB for example. But the closest we have in any popular programming language, certainly.