From 8ea7b88c9b8de8d750b42ceb46b3ec667e21e881 Mon Sep 17 00:00:00 2001 From: Vadim Petrochenkov Date: Thu, 14 Jan 2016 17:08:35 +0300 Subject: Require stability annotations on fields of tuple variants --- src/libstd/path.rs | 24 ++++++++++++++++-------- 1 file changed, 16 insertions(+), 8 deletions(-) (limited to 'src/libstd/path.rs') diff --git a/src/libstd/path.rs b/src/libstd/path.rs index d0b9cc4c460..3956f948eb9 100644 --- a/src/libstd/path.rs +++ b/src/libstd/path.rs @@ -266,27 +266,33 @@ mod platform { pub enum Prefix<'a> { /// Prefix `\\?\`, together with the given component immediately following it. #[stable(feature = "rust1", since = "1.0.0")] - Verbatim(&'a OsStr), + Verbatim(#[cfg_attr(not(stage0), stable(feature = "rust1", since = "1.0.0"))] &'a OsStr), /// Prefix `\\?\UNC\`, with the "server" and "share" components following it. #[stable(feature = "rust1", since = "1.0.0")] - VerbatimUNC(&'a OsStr, &'a OsStr), + VerbatimUNC( + #[cfg_attr(not(stage0), stable(feature = "rust1", since = "1.0.0"))] &'a OsStr, + #[cfg_attr(not(stage0), stable(feature = "rust1", since = "1.0.0"))] &'a OsStr, + ), /// Prefix like `\\?\C:\`, for the given drive letter #[stable(feature = "rust1", since = "1.0.0")] - VerbatimDisk(u8), + VerbatimDisk(#[cfg_attr(not(stage0), stable(feature = "rust1", since = "1.0.0"))] u8), /// Prefix `\\.\`, together with the given component immediately following it. #[stable(feature = "rust1", since = "1.0.0")] - DeviceNS(&'a OsStr), + DeviceNS(#[cfg_attr(not(stage0), stable(feature = "rust1", since = "1.0.0"))] &'a OsStr), /// Prefix `\\server\share`, with the given "server" and "share" components. #[stable(feature = "rust1", since = "1.0.0")] - UNC(&'a OsStr, &'a OsStr), + UNC( + #[cfg_attr(not(stage0), stable(feature = "rust1", since = "1.0.0"))] &'a OsStr, + #[cfg_attr(not(stage0), stable(feature = "rust1", since = "1.0.0"))] &'a OsStr, + ), /// Prefix `C:` for the given disk drive. #[stable(feature = "rust1", since = "1.0.0")] - Disk(u8), + Disk(#[cfg_attr(not(stage0), stable(feature = "rust1", since = "1.0.0"))] u8), } impl<'a> Prefix<'a> { @@ -528,7 +534,9 @@ pub enum Component<'a> { /// /// Does not occur on Unix. #[stable(feature = "rust1", since = "1.0.0")] - Prefix(PrefixComponent<'a>), + Prefix( + #[cfg_attr(not(stage0), stable(feature = "rust1", since = "1.0.0"))] PrefixComponent<'a> + ), /// The root directory component, appears after any prefix and before anything else #[stable(feature = "rust1", since = "1.0.0")] @@ -544,7 +552,7 @@ pub enum Component<'a> { /// A normal component, i.e. `a` and `b` in `a/b` #[stable(feature = "rust1", since = "1.0.0")] - Normal(&'a OsStr), + Normal(#[cfg_attr(not(stage0), stable(feature = "rust1", since = "1.0.0"))] &'a OsStr), } impl<'a> Component<'a> { -- cgit 1.4.1-3-g733a5