Hacker News new | past | comments | ask | show | jobs | submit login

>> And that's exactly what happens in Scala if you cared to look at actual code.

> My example notwithstanding? Heh.

Yes. Just go and read some code instead of using your imagination. Compare for instance TreeSet.apply and List#sorted.

> I am complaining that the language allows me to do something that is dumb in first place. This is attitude towards correctness (the language washing its hands of having to deal with it) is what I dislike.

Then you should dislike Haskel, too, because that's exactly what Haskell allows you to do, too.

  Prelude> let getLargestElement (x:xs) = x
  Prelude> getLargestElement [3,2,1]
  3
  Prelude> getLargestElement [1,2,3]
  1 -- OMG!!!
Haskell is sooo incoherent! I wrote a function that obviously relies on that the input is sorted in a certain way, but Haskell let's me pass arbitrary lists to it! How dumb is that?! Haskell has a really terrible attitude towards correctness!

>> Yeah, sorry. Haskell users know how to deal with different programming languages

> Yes, exactly.

Sorry, but you've been sorted into the I-read-something-about-Haskell-on-the-internet-a-few-minutes-ago-let's-tell-everyone-how-dumb-they-are-to-show-my-new-intellectual-superiority-as-a-Haskell-expert category already, so this doesn't really apply to you.

> The way I deal with Scala is to not use it.

That's perfectly fine, but please stop commenting on things you don't understand. You are only embarrassing yourself.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: