Skip to content
Myr

Merge pull request #2966 from dtolnay/noserdecore

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

Enforce derive cannot be used against serde_core

authored by David Tolnay · committed by GitHub · parents 1b89ff5, 8909fc0 · Browse files · 5 files+27 added−8 removed
This commit

State

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

Diff stats

5 files+27 added−8 removed

  • other:+27 added−8 removed

5 files+27 added−8 removed

modified:serde/src/lib.rs+6 added
254 unmodified lines
255/// Derive macro available if serde is built with `features = ["derive"]`.256#[cfg(feature = "serde_derive")]257#[cfg_attr(docsrs, doc(cfg(feature = "derive")))]258pub use serde_derive::{Deserialize, Serialize};259260#[macro_export]261#[doc(hidden)]262macro_rules! __require_serde_not_serde_core {263 () => {};264}
modified:serde/Cargo.toml-8 removed
modified:serde_core/src/lib.rs+10 added
264 unmodified lines
265mod seed;266267#[cfg(all(not(feature = "std"), no_core_error))]268mod std_error;269270#[macro_export]271#[doc(hidden)]272macro_rules! __require_serde_not_serde_core {273 () => {274 ::core::compile_error!(275 "Serde derive requires a dependency on the serde crate, not serde_core"276 );277 };278}
modified:serde_core/Cargo.toml+8 added
modified:serde_derive/src/dummy.rs+3 added
20 unmodified lines
21 clippy::absolute_paths,22 )]23 const _: () = {24 #use_serde2526 _serde::__require_serde_not_serde_core!();2728 #code29 };30 }31}