6 ms·
"the development SPEED of ruby with the SAFETY of STATIC TYPING" sounds kind of sketchy. Would you say that title is true?
by bwilliams 13y ago
"the development SPEED of ruby with the SAFETY of STATIC TYPING" sounds kind of sketchy. Would you say that title is true?
- ixmatus 13y agoNot only true but faster because less time spent debugging.
- joehillen 13y agoAnd it's faster and easier to add new features because you can refactor without fear.
- bwilliams 13y agoI don't refactor with fear in my Rails apps since they have pretty good test coverage. I'm not saying it's perfect, but I've never had slow development because I wanted to refactor in this context.
- ixmatus 13y agoIt's been slower for me, personally. I write half the tests in Haskell than I had to in Python which means less updating of tests as requirements change. It won't feel slow to you until you've written productive (beyond beginner) software in Haskell.
- pekk 13y agoOnly if you don't count debugging whatever the fancy type system is doing vs. what you need the behavior to be
- chc 13y agoWhat does this mean? I don't think most Haskell users spend a lot of time debugging the type system.
- dllthomas 13y agoNew Haskell developers spend a bit of time figuring out why the types of an expression aren't what they think they are, especially when wading into using some of the libraries with more sophisticated use of types.
- hamidr 13y agoNow, It's "New Haskell developers" vs "New Ruby/RoR developers". Isn't it?
- dllthomas 13y agoI'm not certain what you're asking. If you mean it's unfair to compare experienced Ruby developers to new Haskell developers I agree, I was just explaining where the sentiment was coming from (insofar as it was legitimate).
- coldtea 13y agoWell, New Ruby developers doesn't have the same problem. They can move much faster than the initial uphill struggle that is Haskell. Essentially, there are three sitations: a) Everything is of the same difficulty. b) Haskell is more difficult than Ruby. c) Ruby is more difficult than Haskell. I'd say (b) is a much saner conclusion.
- hamidr 13y agoI think You are assuming that the learner here is already a (imperative or OOP categorized) programmer who is willing to learn these two languages. For ruby still there would be some topics you need to know about before trying to learn language itself, if you are just starting out.
- dllthomas 13y ago"You are assuming that the learner here is already a (imperative or OOP categorized) programmer who is willing to learn these two languages." To be fair, that is not an uncommon situation.
- boothead 13y agoWhat you find if you're doing it right is not only that you get the safety of static typing, but also that the types often lead you towards to solution. Abstractions in Haskell are smaller, more universal and composable than those of say ruby or python. For example the very simple idea of a Monoid (essentially concatenation) can be found in most places either explicitly or if you squint a bit, and once you recognise it a whole set of properties and behaviours can be reused. Also once the structure is in place, they types make for very safe re-factoring and assurance that you haven't broken anything. The only thing that's probably slower than ruby in Haskell is, unfortunately, learning it in the first place :-)
- fractalsea 13y agoAs someone who is quite familiar with abstract algebra, but who has not used much Haskell, I'm curious about why you think of monoids as simply concatenation? Is this the only, or primary, way they are used in Haskell? A monoid could also be the natural numbers combined with addition for example. Would this not be as useful?
- tel 13y agoHaskellers just call them Monoid and happily include anything that's associative+identity. When talking to people not yet familiar with Haskell or abstract algebra, it's commonly a good idea to simplify the notion and call Monoid the same as concatenation. That's all. newtype Sum = Sum { getSum :: Int } instance Monoid Sum where mempty = Sum 0 mappend (Sum a) (Sum b) = Sum (a + b)
- deleted 13y ago[deleted]
- carterschonwald 13y agoyes, thats a commutative monoid. Thinking of a monoid as "concatenation" is much more general concept that includes that one
- judk 13y ago