Make dump output valid JSON
Handle Math::Int128 objects in JSON output

Unfortunately there seems to be a bad interaction between JSON::XS and our
TO_JSON sub for Math::Int128 objects.