Json doesn't need to depend on IoError to implement Encodable #13230
auto merge of #13230 : Kroisse/rust/encodable-json, r=erickt

The implementation of `Encodable<E, S>` for `Json` doesn't need to assume `S` to be `IoError`, only the default encoders for `Json` are depend on it. So this can be parametrize to increase flexiblity. If not, types that implement `Encoder<E>` where `E` is not `IoError` can't be worked with `Json`.