]> git.lizzy.rs Git - rust.git/commit
auto merge of #20910 : sfackler/rust/show-impls, r=alexcrichton
authorbors <bors@rust-lang.org>
Sun, 11 Jan 2015 16:45:48 +0000 (16:45 +0000)
committerbors <bors@rust-lang.org>
Sun, 11 Jan 2015 16:45:48 +0000 (16:45 +0000)
commit2e4cef4e78253beb4c08ed35416fad076d978344
tree5d1aac35761a2a667c1904c8695ba765f2f45cb6
parent2127e0d56d85ff48aafce90ab762650e46370b63
parentb4fae2fba99e713a6d6a8a59caaf1cfba847b50e
auto merge of #20910 : sfackler/rust/show-impls, r=alexcrichton

A derived implementation would not be appropriate for the Buffered types
since the buffer is both huge (64k by default) and full of uninitialized
memory. Instead of printing the whole thing, we display how full it is.

I also altered `MultiWriter` to make it generic over Writers instead of
taking `Box<Writer>` trait objects. `Box<Writer>` implements `Writer` so
existing use cases should continue to work, and this enables a more
useful Show implementation in applicable cases.

The change to `MultiWriter` may break code that uses it, but any fixes
should be easy.

[breaking-change]

r? @alexcrichton