diff options
| author | Mazdak Farrokhzad <twingoow@gmail.com> | 2019-07-07 17:00:17 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2019-07-07 17:00:17 +0200 |
| commit | 3250b8ee596afc9881aee092279efaa57486d2ea (patch) | |
| tree | c445db0b21aa62544140ff60894f770dc8fade07 /src/libserialize | |
| parent | 9cd75fb35f1d24f805c6759fd6236cd708b81ee1 (diff) | |
| parent | 941653b528deb96d5ed13935143db14c45d99d6e (diff) | |
| download | rust-3250b8ee596afc9881aee092279efaa57486d2ea.tar.gz rust-3250b8ee596afc9881aee092279efaa57486d2ea.zip | |
Rollup merge of #62042 - petrochenkov:macstab, r=matthewjasper
Support stability and deprecation checking for all macros RELNOTES: Deprecation attributes on macros now have effect. Fixes https://github.com/rust-lang/rust/issues/34079 Fixes https://github.com/rust-lang/rust/issues/49912 Unblocks https://github.com/rust-lang/rust/pull/62086 Unblocks https://github.com/rust-lang/rust/pull/61000
Diffstat (limited to 'src/libserialize')
| -rw-r--r-- | src/libserialize/json.rs | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/src/libserialize/json.rs b/src/libserialize/json.rs index 726306d60ce..d0007074a82 100644 --- a/src/libserialize/json.rs +++ b/src/libserialize/json.rs @@ -103,8 +103,8 @@ //! //! ```rust //! # #![feature(rustc_private)] -//! extern crate serialize; -//! use serialize::json::{self, ToJson, Json}; +//! extern crate serialize as rustc_serialize; +//! use rustc_serialize::json::{self, ToJson, Json}; //! //! // A custom data structure //! struct ComplexNum { @@ -120,7 +120,7 @@ //! } //! //! // Only generate `RustcEncodable` trait implementation -//! #[derive(Encodable)] +//! #[derive(RustcEncodable)] //! pub struct ComplexNumRecord { //! uid: u8, //! dsc: String, @@ -143,12 +143,12 @@ //! //! ```rust //! # #![feature(rustc_private)] -//! extern crate serialize; +//! extern crate serialize as rustc_serialize; //! use std::collections::BTreeMap; -//! use serialize::json::{self, Json, ToJson}; +//! use rustc_serialize::json::{self, Json, ToJson}; //! -//! // Only generate `Decodable` trait implementation -//! #[derive(Decodable)] +//! // Only generate `RustcDecodable` trait implementation +//! #[derive(RustcDecodable)] //! pub struct TestStruct { //! data_int: u8, //! data_str: String, |
