From 233e17abd5ec68f2a964954fb42c23705e6fa62d Mon Sep 17 00:00:00 2001 From: Nadrieril Date: Sat, 11 Apr 2020 22:58:02 +0100 Subject: spec: update encoding of floating point values to RFC7049bis --- CHANGELOG.md | 1 + dhall-lang | 2 +- dhall/tests/parser/success/unit/DoubleLit16bitB.txt | 1 + dhall/tests/parser/success/unit/DoubleLit32bitB.txt | 1 + dhall/tests/parser/success/unit/DoubleLit64bitB.txt | 1 + dhall/tests/spec.rs | 15 +++------------ 6 files changed, 8 insertions(+), 13 deletions(-) create mode 100644 dhall/tests/parser/success/unit/DoubleLit16bitB.txt create mode 100644 dhall/tests/parser/success/unit/DoubleLit32bitB.txt create mode 100644 dhall/tests/parser/success/unit/DoubleLit64bitB.txt diff --git a/CHANGELOG.md b/CHANGELOG.md index 9ac4b21..f410d16 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,7 @@ #### [Unreleased] +- Update encoding of floating point values to RFC7049bis - Allow unions with mixed kinds - Adjust precedence of `===` and `with` - Fix running tests on Windows. Developing on this lib should now be possible on Windows. diff --git a/dhall-lang b/dhall-lang index 5973964..379e741 160000 --- a/dhall-lang +++ b/dhall-lang @@ -1 +1 @@ -Subproject commit 5973964062be2e7ea6ff7300a46616086dd9143b +Subproject commit 379e741365465313aa77e755077bd81f328ca1bc diff --git a/dhall/tests/parser/success/unit/DoubleLit16bitB.txt b/dhall/tests/parser/success/unit/DoubleLit16bitB.txt new file mode 100644 index 0000000..9ad974f --- /dev/null +++ b/dhall/tests/parser/success/unit/DoubleLit16bitB.txt @@ -0,0 +1 @@ +5.5 diff --git a/dhall/tests/parser/success/unit/DoubleLit32bitB.txt b/dhall/tests/parser/success/unit/DoubleLit32bitB.txt new file mode 100644 index 0000000..f67efa2 --- /dev/null +++ b/dhall/tests/parser/success/unit/DoubleLit32bitB.txt @@ -0,0 +1 @@ +5555.5 diff --git a/dhall/tests/parser/success/unit/DoubleLit64bitB.txt b/dhall/tests/parser/success/unit/DoubleLit64bitB.txt new file mode 100644 index 0000000..f3714c3 --- /dev/null +++ b/dhall/tests/parser/success/unit/DoubleLit64bitB.txt @@ -0,0 +1 @@ +55555555555.5 diff --git a/dhall/tests/spec.rs b/dhall/tests/spec.rs index 37df91d..ee12bc7 100644 --- a/dhall/tests/spec.rs +++ b/dhall/tests/spec.rs @@ -51,7 +51,7 @@ impl FileType { match self { FileType::Text => TestFile::Source(file), FileType::Binary => TestFile::Binary(file), - FileType::Hash => TestFile::Binary(file), + FileType::Hash => TestFile::UI(file), FileType::UI => TestFile::UI(file), } } @@ -449,10 +449,6 @@ fn define_features() -> Vec { false // Pretty sure the test is incorrect || path == "unit/import/urls/quotedPathFakeUrlEncode" - // See https://github.com/pyfisch/cbor/issues/109 - || path == "double" - || path == "unit/DoubleLitExponentNoDot" - || path == "unit/DoubleLitSecretelyInt" }), output_type: FileType::Binary, ..default_feature.clone() @@ -518,13 +514,8 @@ fn define_features() -> Vec { directory: "semantic-hash/success/", variant: SpecTestKind::SemanticHash, exclude_path: Rc::new(|path: &str| { - false - // We don't support bignums - || path == "simple/integerToDouble" - // See https://github.com/pyfisch/cbor/issues/109 - || path == "prelude/Integer/toDouble/0" - || path == "prelude/Integer/toDouble/1" - || path == "prelude/Natural/toDouble/0" + // We don't support bignums + path == "simple/integerToDouble" }), output_type: FileType::Hash, ..default_feature.clone() -- cgit v1.2.3