Skip to content
Myr

Merge pull request #2967 from dtolnay/tricfg

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Specify the cfg in which `tri!` is used

authored by David Tolnay · committed by GitHub · parents 35c9631, b6c7ce8 · Browse files · 1 file+1 added−1 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+1 added−1 removed

  • other:+1 added−1 removed

1 file+1 added−1 removed

modified:serde/src/lib.rs+1 added-1 removed
219 unmodified lines
220// None of this crate's error handling needs the `From::from` error conversion221// performed implicitly by the `?` operator or the standard library's `try!`222// macro. This simplified macro gives a 5.5% improvement in compile time223// compared to standard `try!`, and 9% improvement compared to `?`.224#[allow(unused_macros)]224#[cfg(not(no_serde_derive))]225macro_rules! tri {226 ($expr:expr) => {227 match $expr {228 Ok(val) => val,
36 unmodified lines