Skip to content

Commit f42b258

Browse files
committed
Use explicit re-export of serde_derive to give rustc more info
rustc will start looking behind `#[cfg(FALSE)]` items to start giving better diagnostics. By using an explicit re-export instead of a glob export, we tell rustc that `Deserialize` and `Serialize` exist here.
1 parent 2ba4067 commit f42b258

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

serde/src/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -340,7 +340,7 @@ mod std_error;
340340
extern crate serde_derive;
341341
#[cfg(feature = "serde_derive")]
342342
#[doc(hidden)]
343-
pub use serde_derive::*;
343+
pub use serde_derive::{Deserialize, Serialize};
344344

345345
#[cfg(all(not(no_serde_derive), any(feature = "std", feature = "alloc")))]
346346
mod actually_private {

0 commit comments

Comments
 (0)