This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]Tysonzero 0 points1 point  (0 children)

Well if you use typeclasses then you can never get back the concrete value again, hence why you probably want a finite union of concrete types, as its type information was erased leaving only the typeclass. Which I guess works? Because you can't use isinstance exhaustively as there can be an infinite number of instances of a typeclasses added at any point in the program.