Add more docs

This commit is contained in:
Aleksey Kladov 2021-05-22 16:53:47 +03:00
parent e6776c3e1b
commit 188b0f96f9
20 changed files with 72 additions and 40 deletions

View file

@ -1,5 +1,6 @@
//! FIXME: write short doc here
//! Stateful iteration over token trees.
//!
//! We use this as the source of tokens for parser.
use crate::{Leaf, Subtree, TokenTree};
#[derive(Copy, Clone, Debug, Eq, PartialEq)]
@ -104,7 +105,7 @@ impl<'t> TokenBuffer<'t> {
/// Creates a cursor referencing the first token in the buffer and able to
/// traverse until the end of the buffer.
pub fn begin(&self) -> Cursor {
pub fn begin(&self) -> Cursor<'_> {
Cursor::create(self, EntryPtr(EntryId(0), 0))
}