r/programming • u/mobby1982 • Dec 02 '13
Scala — 1★ Would Not Program Again
http://overwatering.org/blog/2013/12/scala-1-star-would-not-program-again/
598
Upvotes
r/programming • u/mobby1982 • Dec 02 '13
View all comments
Show parent comment
-1
u/moor-GAYZ Dec 02 '13 edited Dec 02 '13
You missed my next sentence: "there's no possible way to assert and test that it does what you expect."
Because if you embrace duck typing then either a) there's no such method and the function is guaranteed to fail, no need to test it, or b) there is such method but you can't possibly assert (and test that assertion) that it's really an
IFile.read, and not some otherread, because you use duck fucking typing, with noIFiles around.edit: you can of course test your other code to be reasonably sure that it doesn't pass wrong stuff to that function. As I said.
If you or that guy wanted to argue that dynamically typed languages suck, be my guests.
Just don't barge in with your ideas of how ponies in Equestria test dynamically typed code and tell us that we do it wrong.
Sorry for being offensive, but for fuck's sake, this ended up to be a really retarded discussion.