Skip to content

Instantly share code, notes, and snippets.

Provisional benchmarks of AST-free serialization puts my WIP branch of uPickle about ~40% faster than circe on my current set of ad-hoc benchmarks, if the encoders/decoders are cached (bigger numbers is better)

playJson Read 2761067
playJson Write 3412630
circe Read 6005895
circe Write 5205007
upickleDefault Read 4543628
upickleDefault Write 3814459
upickleLegacy Read 8393416
class Cell[T](value: T) {
var other: T = value
}
object Test {
def g[T, U](x: T, y: U) = if (util.Random.nextBoolean) x else y
def f1 = g(1f, "abc")
def f2 = g(1: Byte, "abc")
def f3 = g(f1, f2)
/*** Inferred return types: