Deprecate the old config system and make a refined version of the internal config system public. Doing allows the Serializer/Deserializer to be exposed since all of its generic type parameters are now public.
* add option and config traits
* thread options everywhere
* add WithOtherLimit, WithOtherEndian, and update internal to take advantage of it
* wip
* add rest of the public API and fix tests
* dtolnay feedback
* remove serialized_size_bounded and replace it with a use of config
* remove inline from trait method
* finish documentation and add custom reader support
* minor config_map refactor
* doc changes
* add with_(de)serializer functions and their associated modules
... by utilizing that bincode is not human readable.
Uses the changes in https://github.com/serde-rs/serde/pull/1044 which
allows data formats to report that they are not human readable. This
lets certain types serialize themselves into a more compact form as they
know that the serialized form does not need to be readable.
Closes#215
BREAKING CHANGE
This changes how types serialize themselves if they detect the
`is_human_readable` state.
* Make Reader and Writer generic on Endianness
* make alternate API modules
* add test asserting that big endian encoding is different from little endian encoding
* clean up tests
* Remove rustc_serialize support
* Add changelist and bump version number for alpha
* Move refbox and friends into own module
* update changelog
* update travis config
* move serde functions out into global namespace
* Update to serde_derive
* Fix missing Encoder and Decoder imports
* Add test for serializing bytes
* More efficient serialize_bytes
Reported in #serde: blank_name2 tried serializing
`HashMap<String, HashSet<Bytes>>` vs `HashMap<String, HashSet<&Path>>`,
the `&Path` version was done in ~.6 seconds while the
`&[u8]` one took a full 3 seconds more.
* Delegate emit_enum_struct_variant calls to emit_enum_variant
read_enum_struct_variant delegates calls to read_enum_variant which
expects u32 prefix to encode a variant number. Previous implementation
of emit_enum_struct_variant doesn't emit it, making serialized data
invalid.
* Add test to check manual enum encoding
* Removed unused import warning
* pub use InvalidEncoding in serde+rustc_serialize
* Made both fields of InvalidEncoding public so it can be used without Display or Debug traits (e.g. pattern matching)
* Export of InvalidEncoding in rustc_serialize/serde make them visible in `cargo doc`