code: func (p *parser) peek() yaml_event_type_t {
  	if p.event.typ != yaml_NO_EVENT {
  		return p.event.typ
  	}
  	if !yaml_parser_parse(&p.parser, &p.event) {
  		p.fail()
  	}
  	return p.event.typ
  }
docs: // peek peeks at the next event in the event stream,
  // puts the results into p.event and returns the event type.