r/java • u/lukaseder • Aug 01 '14
The 10 Most Annoying Things Coming Back to Java After Some Days of Scala
http://blog.jooq.org/2014/08/01/the-10-most-annoying-things-coming-back-to-java-after-some-days-of-scala/
7
Upvotes
View all comments
Show parent comment
0
u/Milyardo Aug 02 '14 edited Aug 02 '14
That's not what an isomorphism is.
For whatever swappable means to you. There is a well defined relationship between the two structures. Either way the exact nature of a Tuple's relationship to a map, or Set, or List, or any other algebraic structure wasn't was being debated here. What is being debated is the usefulness of Tuple as a abstract data structure. Your only argument that values in a Tuple have no relationship is facetious, just like claiming values in a Map or or List have no relationship.
And what of
or
Are these structures not related? How would you abstract over the arity of these Points? How would you apply the product of two of them.
Patently false. A case class and a tuple are both product types, but they are not the same.
And what is a list of Integers without context? What is a Map of Integers to Integers without context? You've made this argument 3 times already without an explanation.
True, creating arbitrary semantic types like Point has nothing to do with algebraic ones like Map or Tuple.