-
-
Save reinh/5fac07623800a4856eeb to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Renderable a where | |
render :: a -> IO () | |
newtype Rectangle = Rectangle { width :: Double, height :: Double } | |
instance Renderable Rectangle where | |
render = undefined | |
newtype Circle = Circle { radius :: Double } | |
instance Renderable Circle where | |
render = undefined | |
renderEverything :: ??? -- Need to render an unknown number of renderables |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment