Closed alefminus closed 2 years ago
For example:
dhall <<< '{ a = 1, a = 2 }'
gives
Use "dhall --explain" for detailed errors Error: Invalid duplicate field: a 1│ { 2│ a = 1, 3│ a = 2 4│ } (input):1:1
But with serde_dhall:
use serde::Deserialize; use serde_dhall; #[derive(Deserialize)] struct Config { a: usize, } fn main() { let c: Config = match serde_dhall::from_file("config.dhall").parse() { Err(e) => { println!("{}", e); return; }, Ok(c) => c, }; }
Running the debug build (cargo run) on the same config
Type error: error: RecordTypeMergeRequiresRecordType
Further testing shows this isn't dependent on the type at all - i.e. I could have
{ b = 1 b = 2 }
Hi, thanks for reporting this! I've released the best fix I can do at the moment, in v0.11.1.
v0.11.1
For example:
gives
But with serde_dhall:
Running the debug build (cargo run) on the same config
Further testing shows this isn't dependent on the type at all - i.e. I could have