Lines Matching defs:Unexpected
260 unexpected: Cell<Option<Rc<Cell<Unexpected>>>>,
268 inner.set(Unexpected::Some(unexpected_span));
383 unexpected: Rc<Cell<Unexpected>>,
394 pub(crate) enum Unexpected {
397 Chain(Rc<Cell<Unexpected>>),
400 impl Default for Unexpected {
402 Unexpected::None
406 impl Clone for Unexpected {
409 Unexpected::None => Unexpected::None,
410 Unexpected::Some(span) => Unexpected::Some(*span),
411 Unexpected::Chain(next) => Unexpected::Chain(next.clone()),
416 // We call this on Cell<Unexpected> and Cell<Option<T>> where temporarily
425 fn inner_unexpected(buffer: &ParseBuffer) -> (Rc<Cell<Unexpected>>, Option<Span>) {
429 Unexpected::None => return (unexpected, None),
430 Unexpected::Some(span) => return (unexpected, Some(span)),
431 Unexpected::Chain(next) => unexpected = next,
436 pub(crate) fn get_unexpected(buffer: &ParseBuffer) -> Rc<Cell<Unexpected>> {
971 unexpected: Cell::new(Some(Rc::new(Cell::new(Unexpected::None)))),
1281 let unexpected = Rc::new(Cell::new(Unexpected::None));
1307 let unexpected = Rc::new(Cell::new(Unexpected::None));