Trait PeekExpected

Source
pub(crate) trait PeekExpected: Peek {
    // Required method
    fn expected(self) -> Expected;
}
Expand description

A subtrait of Peek for rules that have an expected description.

This is used to automatically build error messages of the form:

expected one of `expected1`, `expected2`, ...

where each expected is the description of a peek rule.

Required Methods§

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementations on Foreign Types§

Source§

impl PeekExpected for Symbol

Implementors§