Skip to content

Commit f3ba185

Browse files
committed
bump version to 2.0.1
1 parent 5500e5e commit f3ba185

File tree

6 files changed

+27
-27
lines changed

6 files changed

+27
-27
lines changed

Cargo.toml

+2-2
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ members = ["derive", "compatibility"]
33

44
[package]
55
name = "bincode"
6-
version = "2.0.0" # remember to update html_root_url and bincode_derive
6+
version = "2.0.1" # remember to update html_root_url and bincode_derive
77
authors = [
88
"Ty Overby <[email protected]>",
99
"Zoey Riordan <[email protected]>",
@@ -32,7 +32,7 @@ alloc = ["serde?/alloc"]
3232
derive = ["bincode_derive"]
3333

3434
[dependencies]
35-
bincode_derive = { path = "derive", version = "2.0.0", optional = true }
35+
bincode_derive = { path = "derive", version = "2.0.1", optional = true }
3636
serde = { version = "1.0", default-features = false, optional = true }
3737
unty = "0.0.4"
3838

derive/Cargo.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "bincode_derive"
3-
version = "2.0.0" # remember to update bincode
3+
version = "2.0.1" # remember to update bincode
44
authors = [
55
"Zoey Riordan <[email protected]>",
66
"Victor Koenders <[email protected]>",

docs/migration_guide.md

+11-11
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ Bincode 2 now has an optional dependency on `serde`. You can either use `serde`,
44

55
## From `Options` to `Configuration`
66

7-
Bincode 1 had the [Options](https://docs.rs/bincode/1/bincode/config/trait.Options.html) trait. This has been replaced with the [Configuration](https://docs.rs/bincode/2.0.0/bincode/config/struct.Configuration.html) struct.
7+
Bincode 1 had the [Options](https://docs.rs/bincode/1/bincode/config/trait.Options.html) trait. This has been replaced with the [Configuration](https://docs.rs/bincode/2/bincode/config/struct.Configuration.html) struct.
88

99
If you're using `Options`, you can change it like this:
1010

@@ -46,10 +46,10 @@ If so, make sure to include bincode 2 with the `serde` feature enabled, and use
4646

4747
```toml
4848
[dependencies]
49-
bincode = { version = "2.0.0", features = ["serde"] }
49+
bincode = { version = "2.0", features = ["serde"] }
5050

5151
# Optionally you can disable the `derive` feature:
52-
# bincode = { version = "2.0.0", default-features = false, features = ["std", "serde"] }
52+
# bincode = { version = "2.0", default-features = false, features = ["std", "serde"] }
5353
```
5454

5555
Then replace the following functions: (`Configuration` is `bincode::config::legacy()` by default)
@@ -70,13 +70,13 @@ Then replace the following functions: (`Configuration` is `bincode::config::lega
7070

7171
```toml,ignore
7272
[dependencies]
73-
bincode = "2.0.0"
73+
bincode = "2.0"
7474
7575
# If you need `no_std` with `alloc`:
76-
# bincode = { version = "2.0.0", default-features = false, features = ["derive", "alloc"] }
76+
# bincode = { version = "2.0", default-features = false, features = ["derive", "alloc"] }
7777
7878
# If you need `no_std` and no `alloc`:
79-
# bincode = { version = "2.0.0", default-features = false, features = ["derive"] }
79+
# bincode = { version = "2.0", default-features = false, features = ["derive"] }
8080
```
8181

8282
Replace or add the following attributes. You are able to use both `serde-derive` and `bincode-derive` side-by-side.
@@ -86,7 +86,7 @@ Replace or add the following attributes. You are able to use both `serde-derive`
8686
| `#[derive(serde::Serialize)]` | `#[derive(bincode::Encode)]` |
8787
| `#[derive(serde::Deserialize)]` | `#[derive(bincode::Decode)]` |
8888

89-
**note:** To implement these traits manually, see the documentation of [Encode](https://docs.rs/bincode/2.0.0/bincode/enc/trait.Encode.html) and [Decode](https://docs.rs/bincode/2.0.0/bincode/de/trait.Decode.html).
89+
**note:** To implement these traits manually, see the documentation of [Encode](https://docs.rs/bincode/2/bincode/enc/trait.Encode.html) and [Decode](https://docs.rs/bincode/2/bincode/de/trait.Decode.html).
9090

9191
**note:** For more information on using `bincode-derive` with external libraries, see [below](#bincode-derive-and-libraries).
9292

@@ -107,10 +107,10 @@ Then replace the following functions: (`Configuration` is `bincode::config::lega
107107
Currently not many libraries support the traits `Encode` and `Decode`. There are a couple of options if you want to use `#[derive(bincode::Encode, bincode::Decode)]`:
108108

109109
- Enable the `serde` feature and add a `#[bincode(with_serde)]` above each field that implements `serde::Serialize/Deserialize` but not `Encode/Decode`
110-
- Enable the `serde` feature and wrap your field in [bincode::serde::Compat](https://docs.rs/bincode/2.0.0/bincode/serde/struct.Compat.html) or [bincode::serde::BorrowCompat](https://docs.rs/bincode/2.0.0/bincode/serde/struct.BorrowCompat.html)
110+
- Enable the `serde` feature and wrap your field in [bincode::serde::Compat](https://docs.rs/bincode/2/bincode/serde/struct.Compat.html) or [bincode::serde::BorrowCompat](https://docs.rs/bincode/2/bincode/serde/struct.BorrowCompat.html)
111111
- Make a pull request to the library:
112112
- Make sure to be respectful, most of the developers are doing this in their free time.
113-
- Add a dependency `bincode = { version = "2.0.0", default-features = false, optional = true }` to the `Cargo.toml`
114-
- Implement [Encode](https://docs.rs/bincode/2.0.0/bincode/enc/trait.Encode.html)
115-
- Implement [Decode](https://docs.rs/bincode/2.0.0/bincode/de/trait.Decode.html)
113+
- Add a dependency `bincode = { version = "2.0", default-features = false, optional = true }` to the `Cargo.toml`
114+
- Implement [Encode](https://docs.rs/bincode/2/bincode/enc/trait.Encode.html)
115+
- Implement [Decode](https://docs.rs/bincode/2/bincode/de/trait.Decode.html)
116116
- Make sure both of these implementations have a `#[cfg(feature = "bincode")]` attribute.

docs/spec.md

+7-7
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,8 @@ By default, this serialization format uses little-endian byte order for basic nu
1515

1616
Endianness can be configured with the following methods, allowing for big-endian serialization when required:
1717

18-
- [`with_big_endian`](https://docs.rs/bincode/2.0.0/bincode/config/struct.Configuration.html#method.with_big_endian)
19-
- [`with_little_endian`](https://docs.rs/bincode/2.0.0/bincode/config/struct.Configuration.html#method.with_little_endian)
18+
- [`with_big_endian`](https://docs.rs/bincode/2/bincode/config/struct.Configuration.html#method.with_big_endian)
19+
- [`with_little_endian`](https://docs.rs/bincode/2/bincode/config/struct.Configuration.html#method.with_little_endian)
2020

2121
### Byte Order Considerations
2222

@@ -31,7 +31,7 @@ Endianness can be configured with the following methods, allowing for big-endian
3131
- Encoded as a single byte
3232
- `false` is represented by `0`
3333
- `true` is represented by `1`
34-
- During deserialization, values other than 0 and 1 will result in an error [`DecodeError::InvalidBooleanValue`](https://docs.rs/bincode/2.0.0/bincode/error/enum.DecodeError.html#variant.InvalidBooleanValue)
34+
- During deserialization, values other than 0 and 1 will result in an error [`DecodeError::InvalidBooleanValue`](https://docs.rs/bincode/2/bincode/error/enum.DecodeError.html#variant.InvalidBooleanValue)
3535

3636
### Numeric Types
3737

@@ -62,7 +62,7 @@ Endianness can be configured with the following methods, allowing for big-endian
6262
- Surrogate code points (0xD800 to 0xDFFF) are not valid
6363
- Invalid Unicode characters can be acquired via unsafe code, this is handled as:
6464
- during serialization: data is written as-is
65-
- during deserialization: an error is raised [`DecodeError::InvalidCharEncoding`](https://docs.rs/bincode/2.0.0/bincode/error/enum.DecodeError.html#variant.InvalidCharEncoding)
65+
- during deserialization: an error is raised [`DecodeError::InvalidCharEncoding`](https://docs.rs/bincode/2/bincode/error/enum.DecodeError.html#variant.InvalidCharEncoding)
6666
- No additional metadata or encoding scheme beyond the raw code point value
6767

6868
All tuples have no additional bytes, and are encoded in their specified order, e.g.
@@ -92,15 +92,15 @@ Encoding an unsigned integer v (of any type excepting u8/i8) works as follows:
9292

9393
`usize` is being encoded/decoded as a `u64` and `isize` is being encoded/decoded as a `i64`.
9494

95-
See the documentation of [VarintEncoding](https://docs.rs/bincode/2.0.0/bincode/config/struct.Configuration.html#method.with_variable_int_encoding) for more information.
95+
See the documentation of [VarintEncoding](https://docs.rs/bincode/2/bincode/config/struct.Configuration.html#method.with_variable_int_encoding) for more information.
9696

9797
### FixintEncoding
9898

9999
- Fixed size integers are encoded directly
100100
- Enum discriminants are encoded as u32
101101
- Lengths and usize are encoded as u64
102102

103-
See the documentation of [FixintEncoding](https://docs.rs/bincode/2.0.0/bincode/config/struct.Configuration.html#method.with_fixed_int_encoding) for more information.
103+
See the documentation of [FixintEncoding](https://docs.rs/bincode/2/bincode/config/struct.Configuration.html#method.with_fixed_int_encoding) for more information.
104104

105105
## Enums
106106

@@ -224,7 +224,7 @@ assert_eq!(encoded.as_slice(), &[
224224
- During serialization, the string is encoded as a sequence of the given bytes.
225225
- Rust strings are UTF-8 encoded by default, but this is not enforced by bincode
226226
- No normalization or transformation of text
227-
- If an invalid UTF-8 sequence is encountered during decoding, an [`DecodeError::Utf8`](https://docs.rs/bincode/2.0.0/bincode/error/enum.DecodeError.html#variant.Utf8) error is raised
227+
- If an invalid UTF-8 sequence is encountered during decoding, an [`DecodeError::Utf8`](https://docs.rs/bincode/2/bincode/error/enum.DecodeError.html#variant.Utf8) error is raised
228228

229229
```rust
230230
let str = "Hello 🌍"; // Mixed ASCII and Unicode

fuzz/Cargo.lock

+5-5
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/lib.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@
7171
//! [`net::TcpStream`]: std::net::TcpStream
7272
//!
7373
74-
#![doc(html_root_url = "https://docs.rs/bincode/2.0.0")]
74+
#![doc(html_root_url = "https://docs.rs/bincode/2.0.1")]
7575
#![crate_name = "bincode"]
7676
#![crate_type = "rlib"]
7777

0 commit comments

Comments
 (0)