From cc03ada4e713f145f2eb1bbf0f131a4c5746cf74 Mon Sep 17 00:00:00 2001 From: Nadrieril Date: Sat, 3 Aug 2019 22:55:51 +0200 Subject: Inline headers --- dhall/build.rs | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'dhall/build.rs') diff --git a/dhall/build.rs b/dhall/build.rs index 3f09d47..5a99def 100644 --- a/dhall/build.rs +++ b/dhall/build.rs @@ -87,6 +87,9 @@ fn main() -> std::io::Result<()> { |path| { // Too slow in debug mode path == "success/largeExpression" + // TODO: Inline headers are not implemented + || path == "success/unit/import/parenthesizeUsing" + || path == "success/unit/import/inlineUsing" }, )?; @@ -100,6 +103,8 @@ fn main() -> std::io::Result<()> { path.starts_with("failure/") // Too slow in debug mode || path == "success/largeExpression" + // TODO: Inline headers are not implemented + || path == "success/unit/import/inlineUsing" }, )?; @@ -118,6 +123,9 @@ fn main() -> std::io::Result<()> { || path == "success/multilet" // See https://github.com/pyfisch/cbor/issues/109 || path == "success/double" + // TODO: Inline headers are not implemented + || path == "success/unit/import/parenthesizeUsing" + || path == "success/unit/import/inlineUsing" }, )?; -- cgit v1.2.3 From 2551e6f91110bfe385fa65dd63e576df637c26fa Mon Sep 17 00:00:00 2001 From: Nadrieril Date: Mon, 5 Aug 2019 18:18:45 +0200 Subject: Add some tests --- dhall/build.rs | 20 ++++++++++++++++++-- 1 file changed, 18 insertions(+), 2 deletions(-) (limited to 'dhall/build.rs') diff --git a/dhall/build.rs b/dhall/build.rs index 5a99def..7e320c5 100644 --- a/dhall/build.rs +++ b/dhall/build.rs @@ -90,6 +90,10 @@ fn main() -> std::io::Result<()> { // TODO: Inline headers are not implemented || path == "success/unit/import/parenthesizeUsing" || path == "success/unit/import/inlineUsing" + // TODO: projection by expression + || path == "success/recordProjectionByExpression" + || path == "success/unit/recordProjectionByExpression" + || path == "success/unit/recordProjectionByExpressionEmpty" }, )?; @@ -105,6 +109,10 @@ fn main() -> std::io::Result<()> { || path == "success/largeExpression" // TODO: Inline headers are not implemented || path == "success/unit/import/inlineUsing" + // TODO: projection by expression + || path == "success/recordProjectionByExpression" + || path == "success/unit/recordProjectionByExpression" + || path == "success/unit/recordProjectionByExpressionEmpty" }, )?; @@ -124,8 +132,11 @@ fn main() -> std::io::Result<()> { // See https://github.com/pyfisch/cbor/issues/109 || path == "success/double" // TODO: Inline headers are not implemented - || path == "success/unit/import/parenthesizeUsing" || path == "success/unit/import/inlineUsing" + // TODO: projection by expression + || path == "success/recordProjectionByExpression" + || path == "success/unit/recordProjectionByExpression" + || path == "success/unit/recordProjectionByExpressionEmpty" }, )?; @@ -139,9 +150,14 @@ fn main() -> std::io::Result<()> { path == "success/simple/integerToDouble" // Too slow || path == "success/remoteSystems" - // TODO: selection by expression + // TODO: projection by expression || path == "success/unit/RecordProjectionTypeEmpty" || path == "success/unit/RecordProjectionTypeNonEmpty" + || path == "success/unit/RecordProjectionTypeNormalizeProjection" + // TODO: fix Double/show + || path == "success/prelude/JSON/number/1" + // the test is wrong + || path == "success/prelude/JSON/Type/0" }, )?; -- cgit v1.2.3 From 482be29e0f03e10c2469ef80bdd6ac7593207dc5 Mon Sep 17 00:00:00 2001 From: Nadrieril Date: Tue, 6 Aug 2019 20:38:06 +0200 Subject: RFC3986 URLs --- dhall/build.rs | 20 ++++++++++++++++++-- 1 file changed, 18 insertions(+), 2 deletions(-) (limited to 'dhall/build.rs') diff --git a/dhall/build.rs b/dhall/build.rs index 7e320c5..cdbd560 100644 --- a/dhall/build.rs +++ b/dhall/build.rs @@ -94,6 +94,12 @@ fn main() -> std::io::Result<()> { || path == "success/recordProjectionByExpression" || path == "success/unit/recordProjectionByExpression" || path == "success/unit/recordProjectionByExpressionEmpty" + // TODO: RFC3986 URLs + || path == "success/unit/import/urls/emptyPath0" + || path == "success/unit/import/urls/emptyPath1" + || path == "success/unit/import/urls/emptyPathSegment" + // Test is broken + || path == "success/unit/import/asLocation" }, )?; @@ -113,6 +119,12 @@ fn main() -> std::io::Result<()> { || path == "success/recordProjectionByExpression" || path == "success/unit/recordProjectionByExpression" || path == "success/unit/recordProjectionByExpressionEmpty" + // TODO: RFC3986 URLs + || path == "success/unit/import/urls/emptyPath0" + || path == "success/unit/import/urls/emptyPath1" + || path == "success/unit/import/urls/emptyPathSegment" + // Test is broken + || path == "success/unit/import/asLocation" }, )?; @@ -137,6 +149,12 @@ fn main() -> std::io::Result<()> { || path == "success/recordProjectionByExpression" || path == "success/unit/recordProjectionByExpression" || path == "success/unit/recordProjectionByExpressionEmpty" + // TODO: RFC3986 URLs + || path == "success/unit/import/urls/emptyPath0" + || path == "success/unit/import/urls/emptyPath1" + || path == "success/unit/import/urls/emptyPathSegment" + // Test is broken + || path == "success/unit/import/asLocation" }, )?; @@ -156,8 +174,6 @@ fn main() -> std::io::Result<()> { || path == "success/unit/RecordProjectionTypeNormalizeProjection" // TODO: fix Double/show || path == "success/prelude/JSON/number/1" - // the test is wrong - || path == "success/prelude/JSON/Type/0" }, )?; -- cgit v1.2.3 From 054121b427b5344b41a0fb230b69d81ea0b5cd0a Mon Sep 17 00:00:00 2001 From: Nadrieril Date: Tue, 6 Aug 2019 20:52:25 +0200 Subject: Change some tests --- dhall/build.rs | 28 +++++++++++++--------------- 1 file changed, 13 insertions(+), 15 deletions(-) (limited to 'dhall/build.rs') diff --git a/dhall/build.rs b/dhall/build.rs index cdbd560..db66e3c 100644 --- a/dhall/build.rs +++ b/dhall/build.rs @@ -92,14 +92,14 @@ fn main() -> std::io::Result<()> { || path == "success/unit/import/inlineUsing" // TODO: projection by expression || path == "success/recordProjectionByExpression" - || path == "success/unit/recordProjectionByExpression" - || path == "success/unit/recordProjectionByExpressionEmpty" + || path == "success/RecordProjectionByType" + || path == "success/unit/RecordProjectionByType" + || path == "success/unit/RecordProjectionByTypeEmpty" + || path == "success/unit/RecordProjectFields" // TODO: RFC3986 URLs || path == "success/unit/import/urls/emptyPath0" || path == "success/unit/import/urls/emptyPath1" || path == "success/unit/import/urls/emptyPathSegment" - // Test is broken - || path == "success/unit/import/asLocation" }, )?; @@ -117,14 +117,13 @@ fn main() -> std::io::Result<()> { || path == "success/unit/import/inlineUsing" // TODO: projection by expression || path == "success/recordProjectionByExpression" - || path == "success/unit/recordProjectionByExpression" - || path == "success/unit/recordProjectionByExpressionEmpty" + || path == "success/RecordProjectionByType" + || path == "success/unit/RecordProjectionByType" + || path == "success/unit/RecordProjectionByTypeEmpty" // TODO: RFC3986 URLs || path == "success/unit/import/urls/emptyPath0" || path == "success/unit/import/urls/emptyPath1" || path == "success/unit/import/urls/emptyPathSegment" - // Test is broken - || path == "success/unit/import/asLocation" }, )?; @@ -147,14 +146,13 @@ fn main() -> std::io::Result<()> { || path == "success/unit/import/inlineUsing" // TODO: projection by expression || path == "success/recordProjectionByExpression" - || path == "success/unit/recordProjectionByExpression" - || path == "success/unit/recordProjectionByExpressionEmpty" + || path == "success/RecordProjectionByType" + || path == "success/unit/RecordProjectionByType" + || path == "success/unit/RecordProjectionByTypeEmpty" // TODO: RFC3986 URLs || path == "success/unit/import/urls/emptyPath0" || path == "success/unit/import/urls/emptyPath1" || path == "success/unit/import/urls/emptyPathSegment" - // Test is broken - || path == "success/unit/import/asLocation" }, )?; @@ -169,9 +167,9 @@ fn main() -> std::io::Result<()> { // Too slow || path == "success/remoteSystems" // TODO: projection by expression - || path == "success/unit/RecordProjectionTypeEmpty" - || path == "success/unit/RecordProjectionTypeNonEmpty" - || path == "success/unit/RecordProjectionTypeNormalizeProjection" + || path == "success/unit/RecordProjectionByTypeEmpty" + || path == "success/unit/RecordProjectionByTypeNonEmpty" + || path == "success/unit/RecordProjectionByTypeNormalizeProjection" // TODO: fix Double/show || path == "success/prelude/JSON/number/1" }, -- cgit v1.2.3 From b3791e91b7cb73778cc21844a6999531bf537f77 Mon Sep 17 00:00:00 2001 From: Nadrieril Date: Tue, 6 Aug 2019 20:59:28 +0200 Subject: Change URL parsing --- dhall/build.rs | 1 + 1 file changed, 1 insertion(+) (limited to 'dhall/build.rs') diff --git a/dhall/build.rs b/dhall/build.rs index db66e3c..2fa63c6 100644 --- a/dhall/build.rs +++ b/dhall/build.rs @@ -100,6 +100,7 @@ fn main() -> std::io::Result<()> { || path == "success/unit/import/urls/emptyPath0" || path == "success/unit/import/urls/emptyPath1" || path == "success/unit/import/urls/emptyPathSegment" + || path == "success/unit/import/urls/potPourri" }, )?; -- cgit v1.2.3 From f20970a24db223f171eac2a3752f840dbf45d72b Mon Sep 17 00:00:00 2001 From: Nadrieril Date: Tue, 6 Aug 2019 21:15:20 +0200 Subject: Auto-generate typechecking tests list --- dhall/build.rs | 36 +++++++++++++++++++++++++++++++++--- 1 file changed, 33 insertions(+), 3 deletions(-) (limited to 'dhall/build.rs') diff --git a/dhall/build.rs b/dhall/build.rs index 2fa63c6..c78f8f9 100644 --- a/dhall/build.rs +++ b/dhall/build.rs @@ -87,7 +87,7 @@ fn main() -> std::io::Result<()> { |path| { // Too slow in debug mode path == "success/largeExpression" - // TODO: Inline headers are not implemented + // TODO: Inline headers || path == "success/unit/import/parenthesizeUsing" || path == "success/unit/import/inlineUsing" // TODO: projection by expression @@ -114,7 +114,7 @@ fn main() -> std::io::Result<()> { path.starts_with("failure/") // Too slow in debug mode || path == "success/largeExpression" - // TODO: Inline headers are not implemented + // TODO: Inline headers || path == "success/unit/import/inlineUsing" // TODO: projection by expression || path == "success/recordProjectionByExpression" @@ -143,7 +143,7 @@ fn main() -> std::io::Result<()> { || path == "success/multilet" // See https://github.com/pyfisch/cbor/issues/109 || path == "success/double" - // TODO: Inline headers are not implemented + // TODO: Inline headers || path == "success/unit/import/inlineUsing" // TODO: projection by expression || path == "success/recordProjectionByExpression" @@ -184,5 +184,35 @@ fn main() -> std::io::Result<()> { |_| false, )?; + make_test_module( + &mut file, + "typecheck", + &tests_dir.join("typecheck/"), + "Typecheck", + |path| { + false + || path == "failure/importBoundary" + // TODO: Inline headers + || path == "failure/customHeadersUsingBoundVariable" + // TODO: projection by expression + || path == "failure/unit/RecordProjectionByTypeFieldTypeMismatch" + || path == "failure/unit/RecordProjectionByTypeNotPresent" + }, + )?; + + make_test_module( + &mut file, + "type_inference", + &tests_dir.join("type-inference/"), + "TypeInference", + |path| { + false + // TODO: projection by expression + || path == "success/unit/RecordProjectionByType" + || path == "success/unit/RecordProjectionByTypeEmpty" + || path == "success/unit/RecordProjectionByTypeJudgmentalEquality" + }, + )?; + Ok(()) } -- cgit v1.2.3 From 3e157f0a05b0b93753ed377332597a37fa379541 Mon Sep 17 00:00:00 2001 From: Nadrieril Date: Tue, 6 Aug 2019 21:28:12 +0200 Subject: Add toMap keyword --- dhall/build.rs | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) (limited to 'dhall/build.rs') diff --git a/dhall/build.rs b/dhall/build.rs index c78f8f9..2d75cbf 100644 --- a/dhall/build.rs +++ b/dhall/build.rs @@ -101,6 +101,8 @@ fn main() -> std::io::Result<()> { || path == "success/unit/import/urls/emptyPath1" || path == "success/unit/import/urls/emptyPathSegment" || path == "success/unit/import/urls/potPourri" + // TODO: toMap + || path == "success/toMap" }, )?; @@ -125,6 +127,8 @@ fn main() -> std::io::Result<()> { || path == "success/unit/import/urls/emptyPath0" || path == "success/unit/import/urls/emptyPath1" || path == "success/unit/import/urls/emptyPathSegment" + // TODO: toMap + || path == "success/toMap" }, )?; @@ -154,6 +158,9 @@ fn main() -> std::io::Result<()> { || path == "success/unit/import/urls/emptyPath0" || path == "success/unit/import/urls/emptyPath1" || path == "success/unit/import/urls/emptyPathSegment" + || path == "success/unit/import/urls/potPourri" + // TODO: toMap + || path == "success/toMap" }, )?; @@ -173,6 +180,10 @@ fn main() -> std::io::Result<()> { || path == "success/unit/RecordProjectionByTypeNormalizeProjection" // TODO: fix Double/show || path == "success/prelude/JSON/number/1" + // TODO: toMap + || path == "success/unit/EmptyToMap" + || path == "success/unit/ToMap" + || path == "success/unit/ToMapWithType" }, )?; @@ -197,6 +208,14 @@ fn main() -> std::io::Result<()> { // TODO: projection by expression || path == "failure/unit/RecordProjectionByTypeFieldTypeMismatch" || path == "failure/unit/RecordProjectionByTypeNotPresent" + // TODO: toMap + || path == "failure/unit/EmptyToMap" + || path == "failure/unit/HeterogenousToMap" + || path == "failure/unit/MistypedToMap1" + || path == "failure/unit/MistypedToMap2" + || path == "failure/unit/MistypedToMap3" + || path == "failure/unit/MistypedToMap4" + || path == "failure/unit/NonRecordToMap" }, )?; @@ -211,6 +230,8 @@ fn main() -> std::io::Result<()> { || path == "success/unit/RecordProjectionByType" || path == "success/unit/RecordProjectionByTypeEmpty" || path == "success/unit/RecordProjectionByTypeJudgmentalEquality" + // TODO: toMap + || path == "success/unit/ToMap" }, )?; -- cgit v1.2.3 From f7b0c6b9c52f65624dc765fb9eaa7d0d94eeae76 Mon Sep 17 00:00:00 2001 From: Nadrieril Date: Tue, 6 Aug 2019 23:03:01 +0200 Subject: Generalize empty list annotations --- dhall/build.rs | 2 ++ 1 file changed, 2 insertions(+) (limited to 'dhall/build.rs') diff --git a/dhall/build.rs b/dhall/build.rs index 2d75cbf..07da3f5 100644 --- a/dhall/build.rs +++ b/dhall/build.rs @@ -103,6 +103,8 @@ fn main() -> std::io::Result<()> { || path == "success/unit/import/urls/potPourri" // TODO: toMap || path == "success/toMap" + // Not a failure anymore + || path == "failure/unit/ListLitEmptyPrecedence" }, )?; -- cgit v1.2.3 From 98e7751fb8deb22685b6991367404515c35f502f Mon Sep 17 00:00:00 2001 From: Nadrieril Date: Wed, 7 Aug 2019 16:28:48 +0200 Subject: Various parsing tweaks --- dhall/build.rs | 4 ---- 1 file changed, 4 deletions(-) (limited to 'dhall/build.rs') diff --git a/dhall/build.rs b/dhall/build.rs index 07da3f5..d3f63ad 100644 --- a/dhall/build.rs +++ b/dhall/build.rs @@ -100,11 +100,8 @@ fn main() -> std::io::Result<()> { || path == "success/unit/import/urls/emptyPath0" || path == "success/unit/import/urls/emptyPath1" || path == "success/unit/import/urls/emptyPathSegment" - || path == "success/unit/import/urls/potPourri" // TODO: toMap || path == "success/toMap" - // Not a failure anymore - || path == "failure/unit/ListLitEmptyPrecedence" }, )?; @@ -160,7 +157,6 @@ fn main() -> std::io::Result<()> { || path == "success/unit/import/urls/emptyPath0" || path == "success/unit/import/urls/emptyPath1" || path == "success/unit/import/urls/emptyPathSegment" - || path == "success/unit/import/urls/potPourri" // TODO: toMap || path == "success/toMap" }, -- cgit v1.2.3 From 6654d441e5741013a8618907773ac54101e3fdf2 Mon Sep 17 00:00:00 2001 From: Nadrieril Date: Wed, 7 Aug 2019 21:38:01 +0200 Subject: Add binary-decode tests --- dhall/build.rs | 23 +++++++++++++++++++++-- 1 file changed, 21 insertions(+), 2 deletions(-) (limited to 'dhall/build.rs') diff --git a/dhall/build.rs b/dhall/build.rs index d3f63ad..1da06ca 100644 --- a/dhall/build.rs +++ b/dhall/build.rs @@ -15,11 +15,15 @@ fn dhall_files_in_dir<'a>( .filter_map(move |path| { let path = path.path(); let path = path.strip_prefix(dir).unwrap(); - if path.extension() != Some(&OsString::from("dhall")) { + let ext = path.extension(); + if ext != Some(&OsString::from("dhall")) + && ext != Some(&OsString::from("dhallb")) + { return None; } + let ext = ext.unwrap(); let path = path.to_string_lossy(); - let path = &path[..path.len() - 6]; + let path = &path[..path.len() - 1 - ext.len()]; let path = if take_a_suffix { if &path[path.len() - 1..] != "A" { return None; @@ -162,6 +166,21 @@ fn main() -> std::io::Result<()> { }, )?; + make_test_module( + &mut file, + "binary_decoding", + &tests_dir.join("binary-decode/"), + "BinaryDecoding", + |path| { + false + // TODO: projection by expression + || path == "success/unit/RecordProjectFields" + || path == "success/unit/recordProjectionByExpression" + // TODO: test is wrong + || path == "success/unit/BuiltinNaturalSubtract" + }, + )?; + make_test_module( &mut file, "beta_normalize", -- cgit v1.2.3 From a01cf8ad53a3839d13aa99a589ba0f2aa796d511 Mon Sep 17 00:00:00 2001 From: Nadrieril Date: Wed, 7 Aug 2019 21:57:51 +0200 Subject: Remove an annoying redundancy in the test harness --- dhall/build.rs | 65 +++++++++++++++++++++++++++------------------------------- 1 file changed, 30 insertions(+), 35 deletions(-) (limited to 'dhall/build.rs') diff --git a/dhall/build.rs b/dhall/build.rs index 1da06ca..3d4611e 100644 --- a/dhall/build.rs +++ b/dhall/build.rs @@ -41,29 +41,37 @@ fn dhall_files_in_dir<'a>( fn make_test_module( w: &mut impl Write, // Where to output the generated code mod_name: &str, // Name of the module, used in the output of `cargo test` - dir: &Path, // Directory containing the tests files + subdir: &str, // Directory containing the tests files feature: &str, // Relevant variant of `dhall::tests::Feature` mut exclude: impl FnMut(&str) -> bool, // Given a file name, whether to exclude it ) -> std::io::Result<()> { + let all_tests_dir = Path::new("../dhall-lang/tests/"); + let tests_dir = all_tests_dir.join(subdir); writeln!(w, "mod {} {{", mod_name)?; - for (name, path) in dhall_files_in_dir(&dir.join("success/"), true) { + for (name, path) in dhall_files_in_dir(&tests_dir.join("success/"), true) { if exclude(&("success/".to_owned() + &path)) { continue; } writeln!( w, - r#"make_spec_test!({}, Success, success_{}, "success/{}");"#, - feature, name, path + r#"make_spec_test!({}, Success, success_{}, "{}/success/{}");"#, + feature, + name, + tests_dir.to_string_lossy(), + path )?; } - for (name, path) in dhall_files_in_dir(&dir.join("failure/"), false) { + for (name, path) in dhall_files_in_dir(&tests_dir.join("failure/"), false) { if exclude(&("failure/".to_owned() + &path)) { continue; } writeln!( w, - r#"make_spec_test!({}, Failure, failure_{}, "failure/{}");"#, - feature, name, path + r#"make_spec_test!({}, Failure, failure_{}, "{}/failure/{}");"#, + feature, + name, + tests_dir.to_string_lossy(), + path )?; } writeln!(w, "}}")?; @@ -71,26 +79,20 @@ fn make_test_module( } fn main() -> std::io::Result<()> { - // Tries to detect when the submodule gets updated; doesn't really work. + // Tries to detect when the submodule gets updated. // To force regeneration of the test list, just `touch dhall-lang/.git` println!("cargo:rerun-if-changed=../dhall-lang/.git"); println!( "cargo:rerun-if-changed=../.git/modules/dhall-lang/refs/heads/master" ); let out_dir = env::var("OUT_DIR").unwrap(); - let tests_dir = Path::new("../dhall-lang/tests/"); let parser_tests_path = Path::new(&out_dir).join("spec_tests.rs"); let mut file = File::create(parser_tests_path)?; - make_test_module( - &mut file, - "parse", - &tests_dir.join("parser/"), - "Parser", - |path| { - // Too slow in debug mode - path == "success/largeExpression" + make_test_module(&mut file, "parse", "parser/", "Parser", |path| { + // Too slow in debug mode + path == "success/largeExpression" // TODO: Inline headers || path == "success/unit/import/parenthesizeUsing" || path == "success/unit/import/inlineUsing" @@ -106,17 +108,11 @@ fn main() -> std::io::Result<()> { || path == "success/unit/import/urls/emptyPathSegment" // TODO: toMap || path == "success/toMap" - }, - )?; + })?; - make_test_module( - &mut file, - "printer", - &tests_dir.join("parser/"), - "Printer", - |path| { - // Failure tests are only for the parser - path.starts_with("failure/") + make_test_module(&mut file, "printer", "parser/", "Printer", |path| { + // Failure tests are only for the parser + path.starts_with("failure/") // Too slow in debug mode || path == "success/largeExpression" // TODO: Inline headers @@ -132,13 +128,12 @@ fn main() -> std::io::Result<()> { || path == "success/unit/import/urls/emptyPathSegment" // TODO: toMap || path == "success/toMap" - }, - )?; + })?; make_test_module( &mut file, "binary_encoding", - &tests_dir.join("parser/"), + "parser/", "BinaryEncoding", |path| { // Failure tests are only for the parser @@ -169,7 +164,7 @@ fn main() -> std::io::Result<()> { make_test_module( &mut file, "binary_decoding", - &tests_dir.join("binary-decode/"), + "binary-decode/", "BinaryDecoding", |path| { false @@ -184,7 +179,7 @@ fn main() -> std::io::Result<()> { make_test_module( &mut file, "beta_normalize", - &tests_dir.join("normalization/"), + "normalization/", "Normalization", |path| { // We don't support bignums @@ -207,7 +202,7 @@ fn main() -> std::io::Result<()> { make_test_module( &mut file, "alpha_normalize", - &tests_dir.join("alpha-normalization/"), + "alpha-normalization/", "AlphaNormalization", |_| false, )?; @@ -215,7 +210,7 @@ fn main() -> std::io::Result<()> { make_test_module( &mut file, "typecheck", - &tests_dir.join("typecheck/"), + "typecheck/", "Typecheck", |path| { false @@ -239,7 +234,7 @@ fn main() -> std::io::Result<()> { make_test_module( &mut file, "type_inference", - &tests_dir.join("type-inference/"), + "type-inference/", "TypeInference", |path| { false -- cgit v1.2.3 From 6d166d3fe0dedb66b4302cc5fb67f696f6688b80 Mon Sep 17 00:00:00 2001 From: Nadrieril Date: Wed, 7 Aug 2019 22:03:33 +0200 Subject: Normalize field selection further by inspecting the argument --- dhall/build.rs | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'dhall/build.rs') diff --git a/dhall/build.rs b/dhall/build.rs index 3d4611e..983fcad 100644 --- a/dhall/build.rs +++ b/dhall/build.rs @@ -196,6 +196,18 @@ fn main() -> std::io::Result<()> { || path == "success/unit/EmptyToMap" || path == "success/unit/ToMap" || path == "success/unit/ToMapWithType" + // Normalize field selection further by inspecting the argument + || path == "success/simplifications/rightBiasedMergeWithinRecordProjectionWithinFieldSelection0" + || path == "success/simplifications/rightBiasedMergeWithinRecordProjectionWithinFieldSelection1" + || path == "success/simplifications/rightBiasedMergeWithinRecursiveRecordMergeWithinFieldselection" + || path == "success/unit/RecordProjectionByTypeWithinFieldSelection" + || path == "success/unit/RecordProjectionWithinFieldSelection" + || path == "success/unit/RecursiveRecordMergeWithinFieldSelection0" + || path == "success/unit/RecursiveRecordMergeWithinFieldSelection1" + || path == "success/unit/RecursiveRecordMergeWithinFieldSelection2" + || path == "success/unit/RightBiasedMergeWithinFieldSelection0" + || path == "success/unit/RightBiasedMergeWithinFieldSelection1" + || path == "success/unit/RightBiasedMergeWithinFieldSelection2" }, )?; -- cgit v1.2.3 From c2cb7d38dfec05b6337aa5dcd0dc3068e73c9a58 Mon Sep 17 00:00:00 2001 From: Nadrieril Date: Wed, 7 Aug 2019 22:25:35 +0200 Subject: Flatten nested let bindings --- dhall/build.rs | 3 +++ 1 file changed, 3 insertions(+) (limited to 'dhall/build.rs') diff --git a/dhall/build.rs b/dhall/build.rs index 983fcad..29e86e3 100644 --- a/dhall/build.rs +++ b/dhall/build.rs @@ -173,6 +173,9 @@ fn main() -> std::io::Result<()> { || path == "success/unit/recordProjectionByExpression" // TODO: test is wrong || path == "success/unit/BuiltinNaturalSubtract" + // TODO: toMap + || path == "success/unit/ToMap" + || path == "success/unit/ToMapAnnotated" }, )?; -- cgit v1.2.3 From e81ab9a553bf82f20fa0b0344926258176a21dac Mon Sep 17 00:00:00 2001 From: Nadrieril Date: Wed, 7 Aug 2019 22:28:36 +0200 Subject: Update dhall-lang submodule --- dhall/build.rs | 1 + 1 file changed, 1 insertion(+) (limited to 'dhall/build.rs') diff --git a/dhall/build.rs b/dhall/build.rs index 29e86e3..b6df3d0 100644 --- a/dhall/build.rs +++ b/dhall/build.rs @@ -259,6 +259,7 @@ fn main() -> std::io::Result<()> { || path == "success/unit/RecordProjectionByTypeJudgmentalEquality" // TODO: toMap || path == "success/unit/ToMap" + || path == "success/unit/ToMapAnnotated" }, )?; -- cgit v1.2.3 From 071ba528cd8c6a222be345ddec7560bb45cca6be Mon Sep 17 00:00:00 2001 From: Nadrieril Date: Thu, 8 Aug 2019 19:33:07 +0200 Subject: Add support for dependent types --- dhall/build.rs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'dhall/build.rs') diff --git a/dhall/build.rs b/dhall/build.rs index b6df3d0..c05df0d 100644 --- a/dhall/build.rs +++ b/dhall/build.rs @@ -199,7 +199,7 @@ fn main() -> std::io::Result<()> { || path == "success/unit/EmptyToMap" || path == "success/unit/ToMap" || path == "success/unit/ToMapWithType" - // Normalize field selection further by inspecting the argument + // TODO: Normalize field selection further by inspecting the argument || path == "success/simplifications/rightBiasedMergeWithinRecordProjectionWithinFieldSelection0" || path == "success/simplifications/rightBiasedMergeWithinRecordProjectionWithinFieldSelection1" || path == "success/simplifications/rightBiasedMergeWithinRecursiveRecordMergeWithinFieldselection" @@ -229,7 +229,10 @@ fn main() -> std::io::Result<()> { "Typecheck", |path| { false + // TODO: Enable imports in typecheck tests || path == "failure/importBoundary" + // Too slow + || path == "success/prelude" // TODO: Inline headers || path == "failure/customHeadersUsingBoundVariable" // TODO: projection by expression -- cgit v1.2.3 From 4d94c3bbf955c5c32cee0651820484c4e4b6cd90 Mon Sep 17 00:00:00 2001 From: Nadrieril Date: Thu, 8 Aug 2019 19:45:52 +0200 Subject: Update dhall-lang submodule --- dhall/build.rs | 3 +++ 1 file changed, 3 insertions(+) (limited to 'dhall/build.rs') diff --git a/dhall/build.rs b/dhall/build.rs index c05df0d..bcb5d1c 100644 --- a/dhall/build.rs +++ b/dhall/build.rs @@ -208,9 +208,12 @@ fn main() -> std::io::Result<()> { || path == "success/unit/RecursiveRecordMergeWithinFieldSelection0" || path == "success/unit/RecursiveRecordMergeWithinFieldSelection1" || path == "success/unit/RecursiveRecordMergeWithinFieldSelection2" + || path == "success/unit/RecursiveRecordMergeWithinFieldSelection3" || path == "success/unit/RightBiasedMergeWithinFieldSelection0" || path == "success/unit/RightBiasedMergeWithinFieldSelection1" || path == "success/unit/RightBiasedMergeWithinFieldSelection2" + || path == "success/unit/RightBiasedMergeWithinFieldSelection3" + || path == "success/unit/RightBiasedMergeEquivalentArguments" }, )?; -- cgit v1.2.3 From 80c8d87db595c91293af75d710464ac5379c7e28 Mon Sep 17 00:00:00 2001 From: Nadrieril Date: Sat, 10 Aug 2019 22:48:21 +0200 Subject: Update dhall-lang submodule --- dhall/build.rs | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) (limited to 'dhall/build.rs') diff --git a/dhall/build.rs b/dhall/build.rs index bcb5d1c..8b23dd9 100644 --- a/dhall/build.rs +++ b/dhall/build.rs @@ -94,8 +94,12 @@ fn main() -> std::io::Result<()> { // Too slow in debug mode path == "success/largeExpression" // TODO: Inline headers - || path == "success/unit/import/parenthesizeUsing" || path == "success/unit/import/inlineUsing" + || path == "success/unit/import/Headers" + || path == "success/unit/import/HeadersDoubleHash" + || path == "success/unit/import/HeadersDoubleHashPrecedence" + || path == "success/unit/import/HeadersHashPrecedence" + || path == "success/unit/import/HeadersInteriorHash" // TODO: projection by expression || path == "success/recordProjectionByExpression" || path == "success/RecordProjectionByType" @@ -117,6 +121,7 @@ fn main() -> std::io::Result<()> { || path == "success/largeExpression" // TODO: Inline headers || path == "success/unit/import/inlineUsing" + || path == "success/unit/import/Headers" // TODO: projection by expression || path == "success/recordProjectionByExpression" || path == "success/RecordProjectionByType" @@ -140,13 +145,13 @@ fn main() -> std::io::Result<()> { path.starts_with("failure/") // Too slow in debug mode || path == "success/largeExpression" - // Too much of a pain to implement; shouldn't make a difference - // since lets disappear on normalization. - || path == "success/multilet" // See https://github.com/pyfisch/cbor/issues/109 || path == "success/double" + || path == "success/unit/DoubleLitExponentNoDot" + || path == "success/unit/DoubleLitSecretelyInt" // TODO: Inline headers || path == "success/unit/import/inlineUsing" + || path == "success/unit/import/Headers" // TODO: projection by expression || path == "success/recordProjectionByExpression" || path == "success/RecordProjectionByType" -- cgit v1.2.3 From 37767c518e3910635b770c8d752f1c67a4391cfc Mon Sep 17 00:00:00 2001 From: Nadrieril Date: Mon, 12 Aug 2019 21:56:43 +0200 Subject: Fix a test --- dhall/build.rs | 2 -- 1 file changed, 2 deletions(-) (limited to 'dhall/build.rs') diff --git a/dhall/build.rs b/dhall/build.rs index 8b23dd9..790ad8e 100644 --- a/dhall/build.rs +++ b/dhall/build.rs @@ -176,8 +176,6 @@ fn main() -> std::io::Result<()> { // TODO: projection by expression || path == "success/unit/RecordProjectFields" || path == "success/unit/recordProjectionByExpression" - // TODO: test is wrong - || path == "success/unit/BuiltinNaturalSubtract" // TODO: toMap || path == "success/unit/ToMap" || path == "success/unit/ToMapAnnotated" -- cgit v1.2.3