func (p *parser) skip() { if p.event._type != C.YAML_NO_EVENT { if p.event._type == C.YAML_STREAM_END_EVENT { panic("Attempted to go past the end of stream. Corrupted value?") } C.yaml_event_delete(&p.event) } if C.yaml_parser_parse(&p.parser, &p.event) == 0 { p.fail() } }
func (p *parser) destroy() { if p.event._type != C.YAML_NO_EVENT { C.yaml_event_delete(&p.event) } C.yaml_parser_delete(&p.parser) }