Skip to content

Instantly share code, notes, and snippets.

@arussel
Created July 10, 2012 07:28
Show Gist options
  • Save arussel/3081814 to your computer and use it in GitHub Desktop.
Save arussel/3081814 to your computer and use it in GitHub Desktop.
class JsonAssoc[A <% JValue](left: (String, A)) {
def ~[B <% JValue](right: (String, B)) = {
val l: JValue = left._2
val r: JValue = right._2
JObject(JField(left._1, l) :: JField(right._1, r) :: Nil)
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment