From 10757bb255dda0cfdc09774b0e317f891f0bfc33 Mon Sep 17 00:00:00 2001 From: Steven Fackler Date: Thu, 23 Jan 2014 23:25:57 -0800 Subject: [PATCH] Hide private traits They show up in docs even though they shouldn't --- message.rs | 4 ++++ types/array.rs | 1 + types/mod.rs | 2 ++ types/range.rs | 1 + 4 files changed, 8 insertions(+) diff --git a/message.rs b/message.rs index 245e5a31..934777cb 100644 --- a/message.rs +++ b/message.rs @@ -118,6 +118,7 @@ pub enum FrontendMessage<'a> { Terminate } +#[doc(hidden)] trait WriteCStr { fn write_cstr(&mut self, s: &str); } @@ -129,6 +130,7 @@ impl WriteCStr for W { } } +#[doc(hidden)] pub trait WriteMessage { fn write_message(&mut self, &FrontendMessage); } @@ -235,6 +237,7 @@ impl WriteMessage for W { } } +#[doc(hidden)] trait ReadCStr { fn read_cstr(&mut self) -> ~str; } @@ -247,6 +250,7 @@ impl ReadCStr for R { } } +#[doc(hidden)] pub trait ReadMessage { fn read_message(&mut self) -> BackendMessage; } diff --git a/types/array.rs b/types/array.rs index 4feb867d..3c24bb0e 100644 --- a/types/array.rs +++ b/types/array.rs @@ -55,6 +55,7 @@ pub trait MutableArray : Array { } } +#[doc(hidden)] trait InternalArray : Array { fn shift_idx(&self, idx: int) -> uint { let shifted_idx = idx - self.dimension_info()[0].lower_bound; diff --git a/types/mod.rs b/types/mod.rs index efcde043..5646238f 100644 --- a/types/mod.rs +++ b/types/mod.rs @@ -239,6 +239,7 @@ pub trait FromSql { fn from_sql(ty: &PostgresType, raw: &Option<~[u8]>) -> Self; } +#[doc(hidden)] trait RawFromSql { fn raw_from_sql(len: uint, raw: &mut R) -> Self; } @@ -482,6 +483,7 @@ pub trait ToSql { fn to_sql(&self, ty: &PostgresType) -> (Format, Option<~[u8]>); } +#[doc(hidden)] trait RawToSql { fn raw_to_sql(&self, w: &mut W); } diff --git a/types/range.rs b/types/range.rs index 7581bfd6..059481db 100644 --- a/types/range.rs +++ b/types/range.rs @@ -134,6 +134,7 @@ enum BoundSide { Lower } +#[doc(hidden)] trait BoundSided { // param is a hack to get around lack of hints for self type fn side(_: Option) -> BoundSide;