Created
June 4, 2015 00:35
-
-
Save rbobillot/f4dbc62e6c92cae382ea 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
implicit def manOf[T: Manifest]( t:T ) = new { | |
def getType = manifest[T] | |
} | |
implicit def range( x:Int ) = new { | |
def ->( n:Int ) = (x to n).toList | |
} | |
val list = (1 -> 7) | |
val res = list.mkString("[", ",", "]") | |
println( list.getType ) | |
println( res ) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment