diff options
author | Alex Crichton <alex@alexcrichton.com> | 2015-01-09 13:48:02 -0600 |
---|---|---|
committer | Alex Crichton <alex@alexcrichton.com> | 2015-01-09 13:48:02 -0600 |
commit | 98212466affbbe841ffea5bc88269732d9edd9f1 (patch) | |
tree | 14fb3a45662fdc0f88694c4f528b940fad091215 /src/parser.rs | |
parent | 35bd36cefd4e54ee965aede90702bb678435e573 (diff) | |
parent | 7a198086706ccd00c032eff07b9ec9b634c323ce (diff) | |
download | milf-rs-98212466affbbe841ffea5bc88269732d9edd9f1.tar.gz milf-rs-98212466affbbe841ffea5bc88269732d9edd9f1.zip |
Merge pull request #46 from vhbit/up-master
Update to master
Diffstat (limited to 'src/parser.rs')
-rw-r--r-- | src/parser.rs | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/parser.rs b/src/parser.rs index f6a1ac3..6df4699 100644 --- a/src/parser.rs +++ b/src/parser.rs @@ -52,9 +52,9 @@ impl<'a> Parser<'a> { /// /// let mut parser = toml::Parser::new(toml); /// match parser.parse() { - /// Some(value) => println!("found toml: {}", value), + /// Some(value) => println!("found toml: {:?}", value), /// None => { - /// println!("parse errors: {}", parser.errors); + /// println!("parse errors: {:?}", parser.errors); /// } /// } /// ``` @@ -651,7 +651,7 @@ impl<'a> Parser<'a> { } Array(ref mut array) => { match array.as_mut_slice().last_mut() { - Some(&Table(ref mut table)) => cur = table, + Some(&mut Table(ref mut table)) => cur = table, _ => { self.errors.push(ParserError { lo: key_lo, @@ -699,7 +699,7 @@ impl<'a> Parser<'a> { added = true; } match into.get_mut(&key) { - Some(&Table(ref mut table)) => { + Some(&mut Table(ref mut table)) => { let any_tables = table.values().any(|v| v.as_table().is_some()); if !any_tables && !added { self.errors.push(ParserError { |