Skip to content

Instantly share code, notes, and snippets.

@missingfaktor
Created June 30, 2015 12:46
Show Gist options
  • Select an option

  • Save missingfaktor/9af57b6401ff4624d804 to your computer and use it in GitHub Desktop.

Select an option

Save missingfaktor/9af57b6401ff4624d804 to your computer and use it in GitHub Desktop.
scala> object Foo {
| implicit def foo(i: Int) = i.toString
| }
warning: there was one feature warning; re-run with -feature for details
defined object Foo
scala> object Bar {
| implicit def foo(s: Symbol) = s.toString
| }
warning: there was one feature warning; re-run with -feature for details
defined object Bar
scala> import Foo._
import Foo._
scala> 3: String
res0: String = 3
scala> import Bar._
import Bar._
scala> 3: String
<console>:16: error: type mismatch;
found : Int(3)
required: String
3: String
^
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment