Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // Classes didn't care but functions do IG? ... O_O
- // Re: https://pastebin.com/wzvwjvDg
- scala> def foo = println("hi")
- foo: Unit
- scala> foo
- hi
- scala> foo()
- ^
- error: Unit does not take parameters
- scala> def foo() = println("wait, what")
- foo: ()Unit
- scala> foo()
- wait, what
- scala> foo
- wait, what
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement