json: move Codec combinators into codec.ml
[module Codec = struct include Codec ... end] in json.ml held ~1600
lines of user-facing codec API (Base, Array, Object, Value, member/
update_member/..., decode_exn/encode_exn) built on top of the low-
level GADT in codec.ml. The split was asymmetric: codec.ml was 372
lines of types + runtime plumbing, json.ml was 3180 lines of
everything else.
Move the combinator body into codec.ml so the two files match their
names: codec.ml now holds the full codec surface, json.ml keeps the
top-level types, the bytesrw parser/encoder, and the AST-flavoured
[module Value] convenience wrappers.
[module Ast = Value] stays - the nested [Codec.Value] codec sub-
module still shadows the [Value] AST in [open Codec] regions.
Renaming the sub-module is a separate pass; this commit is the
structural move only.
The companion error/core/json_brr churn wires up the new
[Error.fail_*] / [Error.failf] surface the moved codec.ml now
depends on.