LibYAML bindings for Rust
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Type Name Latest commit message Commit time
Failed to load latest commit information.
src Use c_char instead of i8 for ffi Dec 11, 2018
tests Rust changes: feature(io) stabilized Apr 5, 2015
.gitignore now generates in $OUT_DIR Aug 28, 2018
.travis.yml Travis-CI now supports Rust. Yay! Sep 4, 2014
Cargo.toml Version bump: v0.3.0 Aug 28, 2018
LICENSE Initial commit May 5, 2014 now generates in $OUT_DIR Aug 28, 2018


libyaml-rust on Travis CI yaml on

LibYAML bindings for Rust


  • LibYAML 0.1.4 or higher
  • Stable Rust (2015/2018 edition)


Parse from memory

extern crate yaml;

use yaml::constructor::*;

yaml::parse_bytes_utf8("[1, 2, 3]".as_bytes()); // => Ok(vec![YamlSequence(~[YamlInteger(1), YamlInteger(2), YamlInteger(3)])])

Parse from Reader

extern crate yaml;

use std::io::BufReader;
use yaml::constructor::*;

let data = "[1, 2, 3]";
let mut reader = BufReader::new(data.as_bytes());

yaml::parse_io_utf8(&mut reader); // => Ok(vec![YamlSequence(~[YamlInteger(1), YamlInteger(2), YamlInteger(3)])])


In the order of what I want to do...