diff --git a/src/expr.rs b/src/expr.rs index e8902d1..21737f5 100644 --- a/src/expr.rs +++ b/src/expr.rs @@ -303,7 +303,8 @@ left_op!(and_unless, comparison, alt!( left_op!(or_op, and_unless, with_modifier!("or", Op::Or)); -named!(pub expression , call!(or_op)); +// XXX nom does not allow pub(crate) here +named_attr!(#[doc(hidden)], pub expression , call!(or_op)); #[allow(unused_imports)] #[cfg(test)] diff --git a/src/vec.rs b/src/vec.rs index e2199ee..8762a5b 100644 --- a/src/vec.rs +++ b/src/vec.rs @@ -109,13 +109,8 @@ named!(range_literal , do_parse!( (num * suffix) )); -named_attr!( -/** -Parses vector expression into the [`Vector`](struct.Vector.html). - -This parser operates on byte sequence instead of `&str` because of the fact that PromQL, like Go, allows raw byte sequences to be included in the string literals (e.g. `{omg='∞'}` is equivalent to both `{omg='\u221e'}` and `{omg='\xe2\x88\x9e'}`). -*/, -pub vector , ws!(do_parse!( +// XXX nom does not allow pub(crate) here +named_attr!(#[doc(hidden)], pub vector , ws!(do_parse!( labels: instant_vec >> range: opt!( delimited!(char!('['), range_literal, char!(']'))