From 83e19d2eada77ded543cd6edf5a4b6351a79a0f9 Mon Sep 17 00:00:00 2001 From: "Felix S. Klock II" Date: Wed, 4 Sep 2013 04:39:14 +0200 Subject: Added explicit pub to several conditions. Enables completion of #6009. --- src/libstd/c_str.rs | 6 +++--- src/libstd/rt/io/mod.rs | 8 +++----- src/libstd/str.rs | 2 +- 3 files changed, 7 insertions(+), 9 deletions(-) (limited to 'src/libstd') diff --git a/src/libstd/c_str.rs b/src/libstd/c_str.rs index 8e7129578ee..6f12e219c3c 100644 --- a/src/libstd/c_str.rs +++ b/src/libstd/c_str.rs @@ -28,10 +28,10 @@ pub enum NullByteResolution { } condition! { - // this should be &[u8] but there's a lifetime issue + // This should be &[u8] but there's a lifetime issue (#5370). // NOTE: this super::NullByteResolution should be NullByteResolution - // Change this next time the snapshot it updated. - null_byte: (~[u8]) -> super::NullByteResolution; + // Change this next time the snapshot is updated. + pub null_byte: (~[u8]) -> super::NullByteResolution; } /// The representation of a C String. diff --git a/src/libstd/rt/io/mod.rs b/src/libstd/rt/io/mod.rs index 75af7ff8444..3b979cc2266 100644 --- a/src/libstd/rt/io/mod.rs +++ b/src/libstd/rt/io/mod.rs @@ -384,19 +384,17 @@ impl ToStr for IoErrorKind { // XXX: Can't put doc comments on macros // Raised by `I/O` operations on error. condition! { - // FIXME (#6009): uncomment `pub` after expansion support lands. // NOTE: this super::IoError should be IoError - // Change this next time the snapshot it updated. - /*pub*/ io_error: super::IoError -> (); + // Change this next time the snapshot is updated. + pub io_error: super::IoError -> (); } // XXX: Can't put doc comments on macros // Raised by `read` on error condition! { - // FIXME (#6009): uncomment `pub` after expansion support lands. // NOTE: this super::IoError should be IoError // Change this next time the snapshot it updated. - /*pub*/ read_error: super::IoError -> (); + pub read_error: super::IoError -> (); } pub trait Reader { diff --git a/src/libstd/str.rs b/src/libstd/str.rs index e4d1b324e73..471ac409cbb 100644 --- a/src/libstd/str.rs +++ b/src/libstd/str.rs @@ -42,7 +42,7 @@ Section: Conditions */ condition! { - not_utf8: (~str) -> ~str; + pub not_utf8: (~str) -> ~str; } /* -- cgit 1.4.1-3-g733a5 From c326ff0c2839862e8307fcbfec84afd288168051 Mon Sep 17 00:00:00 2001 From: "Felix S. Klock II" Date: Wed, 4 Sep 2013 18:07:56 +0200 Subject: Another followup on #6009. Odd that my earlier make checks did not catch this. --- src/libstd/condition.rs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/libstd') diff --git a/src/libstd/condition.rs b/src/libstd/condition.rs index 4d8857c9d1b..9cd2ad79d18 100644 --- a/src/libstd/condition.rs +++ b/src/libstd/condition.rs @@ -193,7 +193,8 @@ mod test { // Issue #6009 mod m { condition! { - sadness: int -> int; + // #6009, #8215: should this truly need a `pub` for access from n? + pub sadness: int -> int; } mod n { -- cgit 1.4.1-3-g733a5