Skip to content

Commit 2deca58

Browse files
committed
Json doesn't need to depend on IoError to implement Encodable #13230
1 parent 1c2ccf0 commit 2deca58

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/libserialize/json.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -732,8 +732,8 @@ impl<'a> ::Encoder<io::IoError> for PrettyEncoder<'a> {
732732
}
733733
}
734734

735-
impl<E: ::Encoder<io::IoError>> Encodable<E, io::IoError> for Json {
736-
fn encode(&self, e: &mut E) -> EncodeResult {
735+
impl<E: ::Encoder<S>, S> Encodable<E, S> for Json {
736+
fn encode(&self, e: &mut E) -> Result<(), S> {
737737
match *self {
738738
Number(v) => v.encode(e),
739739
String(ref v) => v.encode(e),

0 commit comments

Comments
 (0)