Skip to content

Instantly share code, notes, and snippets.

@aturon
Created April 20, 2011 13:54
Show Gist options
  • Save aturon/931391 to your computer and use it in GitHub Desktop.
Save aturon/931391 to your computer and use it in GitHub Desktop.
implicit def str2toInt(s: String): { def toInt: Int } = new {
def toInt: Int = java.lang.Integer.parseInt(s)
}
@aturon
Copy link
Author

aturon commented Apr 20, 2011

Note: "Support for structural types in Scala internally relies on reflection. This makes QuickPimps slower than their 'regular' siblings that are based on dedicated wrapper types."

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment