Function yaml_peg::parser::parse_arc [−][src]
pub fn parse_arc(
doc: &str
) -> Result<(Array<ArcRepr>, AnchorVisitor<ArcRepr>), String>
Expand description
Parse YAML document into std::sync::Arc
data holder.
Return an array of nodes and the anchors.
use yaml_peg::{parse_arc, node_arc}; let (n, anchors) = parse_arc("true").unwrap(); assert_eq!(anchors.len(), 0); assert_eq!(n, vec![node_arc!(true)]);