Skip to content

Instantly share code, notes, and snippets.

@ochafik
Created February 20, 2013 09:48
Show Gist options
  • Save ochafik/4994346 to your computer and use it in GitHub Desktop.
Save ochafik/4994346 to your computer and use it in GitHub Desktop.
implicit class Extensions(self: Any) {
def quoted(quote: String) = quote + self + quote
}
println(10.quoted("'")) // prints "'10'"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment