doc: make Stack and StackElement a little pretty
Also, fix rustdoc warnings.
This commit is contained in:
parent
a91d64873f
commit
ad460446c9
@ -1417,16 +1417,18 @@ enum ParserState {
|
|||||||
|
|
||||||
/// A Stack represents the current position of the parser in the logical
|
/// A Stack represents the current position of the parser in the logical
|
||||||
/// structure of the JSON stream.
|
/// structure of the JSON stream.
|
||||||
/// For example foo.bar[3].x
|
///
|
||||||
|
/// An example is `foo.bar[3].x`.
|
||||||
pub struct Stack {
|
pub struct Stack {
|
||||||
stack: Vec<InternalStackElement>,
|
stack: Vec<InternalStackElement>,
|
||||||
str_buffer: Vec<u8>,
|
str_buffer: Vec<u8>,
|
||||||
}
|
}
|
||||||
|
|
||||||
/// StackElements compose a Stack.
|
/// StackElements compose a Stack.
|
||||||
/// For example, StackElement::Key("foo"), StackElement::Key("bar"),
|
///
|
||||||
/// StackElement::Index(3) and StackElement::Key("x") are the
|
/// As an example, `StackElement::Key("foo")`, `StackElement::Key("bar")`,
|
||||||
/// StackElements compositing the stack that represents foo.bar[3].x
|
/// `StackElement::Index(3)`, and `StackElement::Key("x")` are the
|
||||||
|
/// StackElements compositing the stack that represents `foo.bar[3].x`.
|
||||||
#[derive(PartialEq, Clone, Debug)]
|
#[derive(PartialEq, Clone, Debug)]
|
||||||
pub enum StackElement<'l> {
|
pub enum StackElement<'l> {
|
||||||
Index(u32),
|
Index(u32),
|
||||||
|
Loading…
x
Reference in New Issue
Block a user