Skip to content

Instantly share code, notes, and snippets.

@kmizu
Created March 18, 2011 14:07
Show Gist options
  • Save kmizu/876121 to your computer and use it in GitHub Desktop.
Save kmizu/876121 to your computer and use it in GitHub Desktop.
object OverloadingTest {
def f(x: Long) { println("Long!") }
def f(x: Double) { println("Double!") }
def main(args: Array[String]) {
f(1)
f(1L)
f(1.0)
f(1.0f)
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment