There are some smart strategies here: https://github.com/sirthias/benchmarks/blob/master/src/main/scala/benchmarks/json/ArrayBasedAstParser.scala We should steal some of them.