Commit 08c4dab
committed
Implement Settings for Saturating<T> and NonZero<T>
In both cases, we need to add impls for specific instantiations because
serde does not supply `Serialize`/`Deserialize` impls for the generic
versions. (Those were added later to std.) Serde needs to be at least
version `1.0.198`.
Additionally, for `NonZero`, our impl only applies to
`Option<NonZero<T>>` because `NonZero<T>` does not have a sensible
default value.
Resolves #1611 parent 974a605 commit 08c4dab
2 files changed
+16
-14
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
73 | 73 | | |
74 | 74 | | |
75 | 75 | | |
76 | | - | |
| 76 | + | |
77 | 77 | | |
78 | 78 | | |
79 | 79 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
8 | 8 | | |
9 | 9 | | |
10 | 10 | | |
11 | | - | |
| 11 | + | |
12 | 12 | | |
13 | 13 | | |
14 | 14 | | |
| |||
34 | 34 | | |
35 | 35 | | |
36 | 36 | | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
37 | 51 | | |
38 | 52 | | |
39 | 53 | | |
| |||
45 | 59 | | |
46 | 60 | | |
47 | 61 | | |
48 | | - | |
49 | | - | |
50 | | - | |
51 | | - | |
52 | | - | |
53 | | - | |
54 | | - | |
55 | | - | |
56 | | - | |
57 | | - | |
58 | | - | |
59 | | - | |
60 | 62 | | |
61 | 63 | | |
62 | 64 | | |
| |||
0 commit comments