Merge pull request #79 from silvo38/master
Remove floats from the Decoder.toml field when they get parsed
This commit is contained in:
commit
92b2ff1056
|
@ -57,7 +57,7 @@ impl rustc_serialize::Decoder for Decoder {
|
|||
}
|
||||
fn read_f64(&mut self) -> Result<f64, DecodeError> {
|
||||
match self.toml {
|
||||
Some(Value::Float(f)) => Ok(f),
|
||||
Some(Value::Float(f)) => { self.toml.take(); Ok(f) },
|
||||
ref found => Err(self.mismatch("float", found)),
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue