Changelog for dhall-1.23.0
1.23.0
- BREAKING CHANGE: Fix marshaling union literals
- 1.22.0 introduced two separate bugs in marshaling union literals between
Dhall and Haskell, which this release fixes:
- Dhall enums did not correctly map onto Haskell enums
- New-style union literals (i.e.
< A : T >.A x) were not correctly supported
- See: https://github.com/dhall-lang/dhall-haskell/pull/918
- See: https://github.com/dhall-lang/dhall-haskell/pull/927
- See: https://github.com/dhall-lang/dhall-haskell/pull/936
- 1.22.0 introduced two separate bugs in marshaling union literals between
Dhall and Haskell, which this release fixes:
- BUG FIX: Fix α-normalization
- Version 1.22.0 introduced a new faster evaluation algorithm, but the new algorithm introduced two α-normalization regression, which this release fixes
- The primary effect of this bug was that semantic integrity checks would
fail for expressions that contain an
if/then/else` expression in their normal form - See: https://github.com/dhall-lang/dhall-haskell/pull/931
- See: https://github.com/dhall-lang/dhall-haskell/pull/938
- BUG FIX: Fix merging of sort-level record types
- The language standard requires that
{ a : Kind } ⩓ { b : Kind }is valid, which this change fixes - See: https://github.com/dhall-lang/dhall-haskell/pull/891
- The language standard requires that
- BUG FIX:
dhall freezerespects the--asciiflag - BUG FIX: Don't autocomplete fields for record types
- This prevents the REPL from expanding
{ x : T }.<TAB>to{ x : T }.x - See: https://github.com/dhall-lang/dhall-haskell/pull/937
- This prevents the REPL from expanding
- Support
MonadFail-related changes in GHC 8.8 - Add
crossflag to simplify cross-compilation- This allows the
dhallpackage to be built without usingTemplateHaskell - See: https://github.com/dhall-lang/dhall-haskell/pull/928
- This allows the
- Increase lines of context for error messages
- Error messages now provide at least 20 lines of context instead of 3 before truncating large expressions
- See: https://github.com/dhall-lang/dhall-haskell/pull/916
- Add line numbers to error messages
- The bottom of every Dhall type error includes the original source code, which now has line numbers on the left margin
- See: https://github.com/dhall-lang/dhall-haskell/pull/919
- Expand lower bounds on
megaparsec/transformers-compatdependencies- This is to support
dhallon Debian Sid - See: https://github.com/dhall-lang/dhall-haskell/pull/939
- This is to support
1.22.0
- Supports version 7.0.0 of the standard
- BREAKING CHANGE: Add support for empty alternatives
- The
Uniontype now has an optional (Maybe) type for each alternative - See the changelog for standard version 7.0.0 for more details
- See: https://github.com/dhall-lang/dhall-haskell/pull/863
- The
- BREAKING CHANGE: Remove support for URL fragments
- The
URLtype no longer has a field for a URL fragment since the language no longer supports fragments - See the changelog for standard version 7.0.0 for more details
- See: https://github.com/dhall-lang/dhall-haskell/pull/851
- The
- BREAKING CHANGE: Remove deprecated
Pathtype synonym - BUG FIX: Correctly parse identifiers beginning with
http- i.e.
httpPortwas supposed to be a valid identifier name and now is - See: https://github.com/dhall-lang/dhall-haskell/pull/870
- i.e.
- BUG FIX: Fix
dhall encodebugdhall encodebug was generating binary expressions that were valid (i.e. they would decode correctly) but were non-standard (i.e. hashing them would not match the hash you would normally get from a semantic integrity check)- Semantic integrity checks were not affected by this bug since they used
a slightly different code path that generated the correct binary input to
the hash. Only the
dhall decodesubcommand was affected - See: https://github.com/dhall-lang/dhall-haskell/pull/859
- BUG FIX: Fix for
Dhall.UnionType- This fixes some expressions that would previously fail to marshal into
Haskell, specifically those were the marshalling logic was built using
the
UnionTypeutilities - See: https://github.com/dhall-lang/dhall-haskell/pull/857
- This fixes some expressions that would previously fail to marshal into
Haskell, specifically those were the marshalling logic was built using
the
- Feature: New
--alphaflag to α-normalize command-line output - Performance improvements
- The normalizer is now much faster
- See: https://github.com/dhall-lang/dhall-haskell/pull/876
1.21.0
- Supports version 6.0.0 of the language standard
- BREAKING CHANGE: Remove the
constructorskeyword- ... as standardized in version 6.0.0 of the language standard
- The deprecation cycle is over, so the keyword is no longer supported
- For more details, see: https://github.com/dhall-lang/dhall-lang/wiki/Migration%3A-Deprecation-of-constructors-keyword
- See: https://github.com/dhall-lang/dhall-haskell/pull/829
- BREAKING CHANGE: CBOR-encode only special
Doubles as half-floats- ... as standardized in version 6.0.0 of the language standard
- CBOR
Doubles exceptInfinity/-Infinity/NaN/0.0are now encoded in at least 32 bits - See: https://github.com/dhall-lang/dhall-haskell/pull/822
- BREAKING CHANGE: Sort record and union fields when CBOR-encoding
- Fields and alternatives are now sorted when serialized
- This does not affect semantic integrity checks, which already sorted these fields/alternatives before hashing expressions
- This does affect the serialization of expressions that have not been normalized (e.g. uninterpreted expressions transmitted over the wire)
- See: https://github.com/dhall-lang/dhall-haskell/pull/835
- BUG FIX: Fix non-exhaustive pattern match in
dhall lint- This fixes:
Irrefutable pattern failed for pattern Let (l' :| ls') d' - This bug would cause
dhall lintto fail on some nestedlet/inexpressions - See: https://github.com/dhall-lang/dhall-haskell/pull/780
- See: https://github.com/dhall-lang/dhall-haskell/pull/784
- This fixes:
- BUG FIX: Don't fail if
$HOMEenvironment variable is unset- The interpreter was incorrectly throwing an exception if
HOMEwas unset - The standard requires that implementations should handle the
HOMEenvironment variable being missing - See: https://github.com/dhall-lang/dhall-haskell/pull/789
- The interpreter was incorrectly throwing an exception if
- Feature: Remove version tag from semantic integrity check
- ... as standardized in version 6.0.0 of the language standard
- This is not a breaking change because this change also includes backwards-compatible support for semantic integrity checks produced by older versions of the interpreter
- Feature: Support Unicode path components
- ... as standardized in version 6.0.0 of the language standard
- You can now use Unicode in path components if they are quoted
- i.e.
./families/"禺.dhall"is now legal
- Feature: Add
Text/showbuilt-in- ... as standardized in version 6.0.0 of the language standard
- You can now convert a
Textliteral to its equivalent Dhall source code (which is itself aTextliteral) - This comes in handy when using Dhall code to generate JSON or Dhall code
- See: https://github.com/dhall-lang/dhall-haskell/pull/811
- Feature: Add
--immediate-dependencies/--transitive-dependenciesflags fordhall resolve- You can now retrieve all of your immediate or transitive dependencies as a textual list
- This simplifies integration with other command-line tools (such as file watchers)
- See: https://github.com/dhall-lang/dhall-haskell/pull/795
- See: https://github.com/dhall-lang/dhall-haskell/pull/803
- Feature:
dhall freezenow only freezes remote imports by defaultdhall freezeused to freeze all imports (including local imports and environment variables)- Now
dhall freezeonly freezes remote imports by default, which is what most users want - You can install freeze all imports using the
--allflag - See: https://github.com/dhall-lang/dhall-haskell/pull/808
- Feature:
:saveand:loadREPL state:savewith no arguments now saves the REPL state to a.dhall-repl-Nfile- The file format is a list of
dhall replcommands - You can use
:loadto load the saved state back into the REPL - See: https://github.com/dhall-lang/dhall-haskell/pull/807
- Feature: Add
:hashcommand todhall repl- This lets you conveniently hash expressions within the
dhall repl - See: https://github.com/dhall-lang/dhall-haskell/pull/806
- This lets you conveniently hash expressions within the
- Feature: Add
--checkflag todhall format- Use this to check if the input is already formatted
- Useful for continuous integration when you want to ensure that all code under version control remains formatted
- See: https://github.com/dhall-lang/dhall-haskell/pull/810
- Feature: Add
UnionInputTypebuilder forInputTypes- This is the union analog of
RecordInputType, letting you build a record explicitly instead of deriving the instance using GHC generics - See: https://github.com/dhall-lang/dhall-haskell/pull/775
- This is the union analog of
- Feature: Add
:set/:unsetcommands todhall repl- You can use these commands to set or unset command-line options
- Currently only setting/unsetting
--explainis supported
- Standards-compliance fixes:
- Documentation fixes:
- Test fixes:
- Improved error messages:
- Formatting fixes:
- REPL fixes:
1.20.1
- BUG FIX: Fix binary encoding to use correct standard version
- This fixes computed hashes to correctly match standard version 5.0.0
- This is not marked as a breaking change since it is a bug fix. The 1.20.0 release will be blacklisted on Hackage and users should upgrade from 1.19.* directly to 1.20.1
- See: https://github.com/dhall-lang/dhall-haskell/pull/771
1.20.0
- Supports version 5.0.0 of the language standard
- BREAKING CHANGE TO THE LANGUAGE: Implement standardized support for multi-line
literals
- This updates the multi-line support to match the standard
- This is a breaking change because empty lines within the multi-line literal now require leading whitespace whereas previously they did not
- This is also a breaking change because now a newline is required after
the opening
''quotes whereas previously it was not required - If you use
dhall formatthen your multi-line literals already have the necessary leading whitespace
- BREAKING CHANGE TO THE LANGUAGE:
constructors x = x- Now the
constructorskeyword behaves like an identity function, since constructors can already be accessed as fields off the original union type. - This is a breaking change since any record of terms that contains a
constructorsfield will now be a forbidden mixed record of types and terms. - This is also a breaking change if you annotated the type of what used to
be a
constructorsrecord. dhall lintwill now remove the obsoleteconstructorskeyword for you- See: https://github.com/dhall-lang/dhall-haskell/pull/693
- See: https://github.com/dhall-lang/dhall-haskell/pull/701
- Now the
- BREAKING CHANGE TO THE API: Restore
Parentconstructor forLocaltype- This more closely matches the standard and also enables
dhall formatto produce a leading../for imports instead of./../ - See: https://github.com/dhall-lang/dhall-haskell/pull/718
- This more closely matches the standard and also enables
- BUG FIX: Fix type-checking bug for unions
- The first fix was that the inferred type was wrong for unions where alternatives were types or kinds
- The second fix was that unions that mixed terms/types/kinds were not properly rejected
- See: https://github.com/dhall-lang/dhall-haskell/pull/763
- BUG FIX: Change how
dhall replhandles prior definitions- This changes the REPL to handle previous bindings as if they were
defined using a large
letexpression instead of adding them to the context - This fixes some type-checking false negatives
- See: https://github.com/dhall-lang/dhall-haskell/pull/729
- This changes the REPL to handle previous bindings as if they were
defined using a large
- Feature: Autocomplete for
dhall repl- You can now auto-complete record fields, union constructors, and identifiers that are in scope
- See: https://github.com/dhall-lang/dhall-haskell/pull/727
- Feature: GHCJS support
dhallcan now be built using GHCJS, although some features are still not supported for GHCJS, such as:- Semantic integrity checks
- Custom HTTP headers
- Also, HTTP imports only work for URLs that support CORS
- See: https://github.com/dhall-lang/dhall-haskell/pull/739
- Feature: Add support for records of records of types
- You can now nest records of types
- See: https://github.com/dhall-lang/dhall-haskell/pull/700
- Feature: Add
:quitcommand fordhall repl - Feature: Add
--jsonflag fordhall {encode,decode}- You can now produce/consume CBOR expressions via JSON instead of binary
- See: https://github.com/dhall-lang/dhall-haskell/pull/717
- Feature: Add decoding logic for
as Text- You can now preserve the
as Textqualifier on imports when serializing them - See: https://github.com/dhall-lang/dhall-haskell/pull/712
- You can now preserve the
- Prenormalize substituted expressions
- This is a performance improvement that reduces the time and memory consumption when normalizing expressions
- See: https://github.com/dhall-lang/dhall-haskell/pull/765
1.19.1
- BUG FIX: Fix serious
dhall lintbugdhall lintwould sometimes removeletexpressions that were still in use- See: https://github.com/dhall-lang/dhall-haskell/pull/703
- BUG FIX: Fix import caching efficiency bug
- Some imports were being wastefully fetched multiple times
- See: https://github.com/dhall-lang/dhall-haskell/pull/702
- Feature: Generate dot graph to visualize import graph
- Use the
dhall resolve --dotcommand - See: https://github.com/dhall-lang/dhall-haskell/pull/698
- See: https://github.com/dhall-lang/dhall-haskell/pull/713
- Use the
- Improve HTTP error messages
1.19.0
- Supports version 4.0.0 of the language standard
- BREAKING CHANGE TO THE LANGUAGE AND API: Prevent Hurkens' paradox
- This fixes a type-checking soundness bug which permitted infinite loops
- This is a breaking change because infinite loops are no longer possible
- This is also a breaking change because a record of types is now treated as a kind instead of a type
- See: https://github.com/dhall-lang/dhall-haskell/pull/680
- BREAKING CHANGE TO THE LANGUAGE AND API:
Doubles are now double-precision floating point numbers- This restricts the range of
Doubles to IEEE 754 double-precision floating point - This also implies that you can no longer convert
Scientificvalues toDhallexpressions (i.e. noInjectinstance forScientific) - See: https://github.com/dhall-lang/dhall-haskell/pull/667
- This restricts the range of
- BREAKING CHANGE TO THE API: Preserve field order for record projection
- The API uses a new
Dhall.Set.Settype instead ofData.Set.Set - See: https://github.com/dhall-lang/dhall-haskell/pull/670
- The API uses a new
- BREAKING CHANGE TO THE API: Add support for multi-
letexpressions- This changes the
Letconstructor to now support storing multiple bindings perletexpression - See: https://github.com/dhall-lang/dhall-haskell/pull/675
- This changes the
- Access constructors as if they were fields of the union type
- In other words:
< Left : Bool | Right : Natural >.Left - See: https://github.com/dhall-lang/dhall-haskell/pull/657
- In other words:
- Support GHC 8.6
- Add support for quoted path components
- i.e.
/"foo"/bar/"baz qux"orhttps://example.com/foo/"bar?baz"?qux - See: https://github.com/dhall-lang/dhall-haskell/pull/690
- i.e.
- Fix parsing of
//\\operator - Preserve Unicode characters when formatting code
- Allow identifier names to begin with
Some - Add
subExpressionsTraversal - Add
normalizeWithMfor monadic normalization - Custom normalizers now take precedence over default normalization logic
- This allows one to override the implementation of built-in operators
- See: https://github.com/dhall-lang/dhall-haskell/pull/684
1.18.0
- Supports version 3.0.0 of the language standard:
- BREAKING CHANGE TO THE LANGUAGE AND API: New
Some/Noneconstructors forOptionalvalues- Example:
[ Some 1, None Natural ] - This is a breaking change to the language because
SomeandNoneare now reserved keywords - This is a breaking change to the API because
SomeandNoneare new constructors for theExprtype
- Example:
- BREAKING CHANGE TO THE LANGUAGE AND API: Support for kind polymorphism
- This adds a new
Sortconstant aboveKindin the hierarchy - i.e.
Type : Kind : Sort - This is a breaking change to the language because
Sortis now a reserved keyword - This is a breaking change to the API because
Sortis a new constructor for theExprtype
- This adds a new
- BREAKING CHANGE TO THE API: New
Dhall.Mapmodule- This replaces
InsOrdHashMapin the API - The primary motivation is to improve performance and to remove the
dependency on
insert-ordered-containers
- This replaces
- BREAKING CHANGE TO THE API: Use standard version instead of protocol version
- The binary protocol is now versioned alongside the standard
- The
ProtocolVersiontype is renamed toStandardVersionand the --protocol-versionoption is renamed to--standard-version- See: https://github.com/dhall-lang/dhall-haskell/pull/634
- BUG FIX: Fix import chaining for custom header imports
- BUG FIX: Fix import chaining for imports protected by semantic integrity checks
- BUG FIX: Record literals and types produced by
∧/⫽/⩓are now sorted- This ensures that β-normalization is idempotent
- See: https://github.com/dhall-lang/dhall-haskell/pull/572
- BUG FIX:
dhall freezenow correctly handles the starting file being located outside the current working directory - BUG FIX: Fix parsing of IPv4-mapped IPv6 addresses
- FEATURE: New
--asciiflag for ASCII output - FEATURE: New
dhall encodeanddhall decodesubcommands- These allow you to transform Dhall source code to and from its binary representation
- See: https://github.com/dhall-lang/dhall-haskell/pull/588
- LARGE parsing performance improvements
- Parsing is about 10x-100x faster on most code
- See: https://github.com/dhall-lang/dhall-haskell/pull/591
- See: https://github.com/dhall-lang/dhall-haskell/pull/592
- See: https://github.com/dhall-lang/dhall-haskell/pull/597
- See: https://github.com/dhall-lang/dhall-haskell/pull/601
- See: https://github.com/dhall-lang/dhall-haskell/pull/602
- See: https://github.com/dhall-lang/dhall-haskell/pull/604
- See: https://github.com/dhall-lang/dhall-haskell/pull/606
- Type-checking performance improvements:
- Normalization performance improvements:
dhall freezenow caches the imports as it freezes themdhall freezenow refreezes imports with invalid semantic integrity checksdhall freezenow adds a trailing newline- Build against
megaparsec-7.0.* - Support GHC 8.6
- Support GHC all the way back to 7.10.3
- Improvements to error messages:
1.17.0
- This release corresponds to version 2.0.0 of the language standard
- BREAKING CHANGE TO THE LANGUAGE AND API: Binary serialization support
- This is a breaking change to the hash for all semantic integrity checks
- The hash used by the semantic integrity check is now based on the binary representation instead of a text representation of the expression
- You can pin the new hashes by supplying the
--protocol-version 1.0option on the command line until you need support for newer language features - This also includes a breaking change to
ImportTypein the API
- BREAKING CHANGE TO THE LANGUAGE: Disallow combining records of terms and
types
- This is mainly for consistency and to improve type errors that would have otherwise happened further downstream
- This should not affect the vast majority of code
- See: https://github.com/dhall-lang/dhall-haskell/pull/538
- BUG FIX: Semantic integrity checks now work for imported expression using
the
constructorskeyword - BUG FIX: Fix α-normalization of expressions with bound variables named
_ - BUG FIX: Fix
isNormalizedto matchnormalize - BUG FIX:
dhall lintnow correctly handles nestedletexpressions - FEATURE: Imports protected by a semantic integrity check are now cached
- The default
dhallcommand no longer outputs the type tostderr- You can add back the type as a type annotation using the
--annotateswitch - See: https://github.com/dhall-lang/dhall-haskell/pull/544
- You can add back the type as a type annotation using the
- New utilities for building
InputTypes - Improve parsing performance for long variable names
- More succinct type diffs for function types
- Identifier names can now begin with keywords
- i.e.
ifChangedandlettuceare now legal identifiers - See: https://github.com/dhall-lang/dhall-haskell/pull/551
- i.e.
1.16.1
- Fix test failure due to missing test data file
1.16.0
- BREAKING CHANGE: Consolidate
inputfamily of functions- These now take a record of options
- This also
_stackfield of theStatustype from[Import]toNonEmpty Import
- Permit
$in quoted variable names
1.15.1
- Fix infinite loop when formatting expressions containing
?
1.15.0
- BREAKING CHANGE TO THE API: Support alternative imports using new
?operator- This adds a new constructor which affects exhaustive pattern matches
- See: https://github.com/dhall-lang/dhall-haskell/pull/473
- BREAKING CHANGE TO THE API: Add
Integer/toDoublebuilt-in function- This adds a new constructor which affects exhaustive pattern matches
- See: https://github.com/dhall-lang/dhall-haskell/pull/434
- BREAKING CHANGE TO THE API: Use strict
Textinstead of lazyText - BREAKING CHANGE TO THE API: Remove
Buildablein favor ofPretty - BREAKING CHANGE TO THE API: Removed the
Parentconstructor fromFilePrefix- Instead, use
Herewith a".."prefix. - See: https://github.com/dhall-lang/dhall-haskell/pull/407
- Instead, use
- BUG FIX: Disallow duplicate fields in records
- BUG FIX: Fix stripping of leading whitespace in multi-line strings
- BUG FIX: Fix formatting field access of an import
- Add
dhall freezecommand - Add
dhall diffcommand - Add
dhall lintcommand - Change
dhall-repl/dhall-hash/dhall-formattodhallsubcommands- i.e.
dhall repl/dhall hash/dhall format - See: https://github.com/dhall-lang/dhall-haskell/pull/435
- See: https://github.com/dhall-lang/dhall-haskell/pull/452
- i.e.
- Add
with-httpcabal flag to disable support for remote imports - Added
inputFromandinputFromWith- These allow naming the file that the expression is coming from for better error messages
- See: https://github.com/dhall-lang/dhall-haskell/pull/464
- Performance improvements
- Tutorial recommends GitHub for Prelude instead of IPFS
- Pretty-print expressions in type errors
- Formatting improvements
- Diff improvements
1.14.0
- BREAKING CHANGE TO THE LANGUAGE: Switch grammar of
NaturalandIntegerNaturalnumber literals are now unsigned andIntegerliterals always require a sign- This is a VERY disruptive change to most Dhall code in the wild but was unanimously agreed upon here: https://github.com/dhall-lang/dhall-lang/issues/138
- See also: https://github.com/dhall-lang/dhall-haskell/pull/381
- BREAKING CHANGE TO THE LANGUAGE: Drop support for importing directories
- Importing
dir/used to resolve todir/@, which is no longer supported - See: https://github.com/dhall-lang/dhall-haskell/pull/384
- Importing
- BREAKING CHANGE TO THE LANGUAGE: Change to the grammar for imports
- File path components can no longer contain
#or?characters - URL imports must now contain at least one path component
- URL path components must match the grammar for file path components
- See: https://github.com/dhall-lang/dhall-haskell/pull/390
- File path components can no longer contain
- BREAKING CHANGE TO THE API: Rename
Path{,Mode,Hashed,Type}toImport{,Mode,Hashed,Type}- In practice this change is not breaking for the most common use cases
since this also provides a
Pathtype synonym for backwards compatibility - See: https://github.com/dhall-lang/dhall-haskell/pull/376
- In practice this change is not breaking for the most common use cases
since this also provides a
- BUG FIX: Fix α-equivalence bug when type-checking
mergemergeexpressions would sometimes reject valid code due to a type-checking bug- See: https://github.com/dhall-lang/dhall-haskell/pull/394
- Improve import caching
- Increase upper bound on
tasty - Fix lower bound on
insert-ordered-containers
1.13.1
- Increase upper bound on
ansi-terminalandmegaparsec
1.13.0
- BUG FIX: Fix semantic integrity hashing support
- Both parsing and pretty-printing semantic hashes were broken since version 1.11.0
- See: https://github.com/dhall-lang/dhall-haskell/pull/345
- BUG FIX: Allow leading whitespace in interpolated expresssions
- BUG FIX: Fix
deriving (Interpret)for sum types- The types of alternatives were not correctly included in the corresponding Dhall type
- See: https://github.com/dhall-lang/dhall-haskell/pull/348
- BREAKING CHANGE TO LANGUAGE: Records cannot store both types and terms
- Records can also not store type-level functions (like
List)- Records might be allowed to store type-level functions again in the future
- This fixes a potential soundness bug
- The primarily practical consequence of this change is that if you are hosting a "package" then you will need to split terms and types from your package into different records for your users to import
- This also implies removing the
./Monoidtype-level function from the./Prelude/package.dhallrecord - See: https://github.com/dhall-lang/dhall-haskell/pull/335
- Records can also not store type-level functions (like
- BREAKING CHANGE TO THE API: Replace
trifectawithmegaparsec- This change the API to use the
Parsertype frommegaparsec - This also slightly changes the type of
exprFromText - If you program using the type classes provided by the
parserslibrary then this is not a breaking change as that interface is preserved - See: https://github.com/dhall-lang/dhall-haskell/pull/268
- This change the API to use the
- BREAKING CHANGE TO THE API: New
⩓operator for merging record types- Example:
{ foo : Text } ⩓ { bar : Bool } = { foo : Text, bar : Bool } - This is breaking because it adds a new constructor to the
Exprtype - See: https://github.com/dhall-lang/dhall-haskell/pull/342
- Example:
- BREAKING CHANGE TO THE API: New support for projecting a subset of fields
- Example:
{ x = 1, y = 2, z = 3 }.{ x, y } = { x = 1, y = 2 } - This is breaking because it adds a new constructor to the
Exprtype - See: https://github.com/dhall-lang/dhall-haskell/pull/350
- Example:
- API+UX feature: New support for pretty-printing diffs of Dhall expressions
- Error messages also use this feature to simplify large type mismatches
- There is also a new
Dhall.Diffmodule - See: https://github.com/dhall-lang/dhall-haskell/pull/336
- Add
version,resolve,type, andnormalizesub-commands to interpreter - Support GHC 7.10.3
:typecommand indhall-replnow only displays the type- Before it would also display the original expression
- See: https://github.com/dhall-lang/dhall-haskell/pull/344
- Trim dependency tree
1.12.0
- Additional changes to support GHC 8.4
- BREAKING CHANGE TO API: Replace dependency on
text-formatwithformatting- This replace the
Data.Text.Buildable.Buildableinstances withFormatting.Buildable.Buildableinstances, which is why this is a breaking change text-formatis no longer maintained and blocking GHC 8.4 support- See: https://github.com/dhall-lang/dhall-haskell/pull/330
- This replace the
1.11.1
- Support GHC 8.4
- Fix α-normalization bug
- Note that this is not a type-checking bug. This only affects users who
were directly using the
alphaNormalizefunction from the Haskell API becauseletexpressions were not correctly α-normalized - See: https://github.com/dhall-lang/dhall-haskell/pull/319
- Note that this is not a type-checking bug. This only affects users who
were directly using the
- Slight tweak to syntax highlighting
- Increase upper bound on
ansi-terminalandexceptions
1.11.0
- BREAKING CHANGE TO THE API: Fix
{Natural,Optional,List}/buildsemantics to match standard- This is a breaking change because the
OptionalLitandListLitconstructors changed their representations to efficiently support the standard semantics ListLitnow stores aData.Sequence.Seqinstead of aData.Vector.VectorOptionalLitnow stores aMaybeinstead of aData.Vector.Vector- See: https://github.com/dhall-lang/dhall-haskell/pull/300
- This is a breaking change because the
- BREAKING CHANGE TO THE COMMAND LINE:
dhallexecutable always formats output- Previously you had to opt into formatting using
--pretty - Now formatting is obligatory and the
--prettyflag is gone - See: https://github.com/dhall-lang/dhall-haskell/pull/303
- Previously you had to opt into formatting using
- Feature: New
:savecommand fordhall-repl- Now you can save an expression to a file:
./yourFile = someExpression - See: https://github.com/dhall-lang/dhall-haskell/pull/309
- Now you can save an expression to a file:
- Improvement: Add new simplifications to match standard
- Improvement: Fix equivalence check to match standard
- Practically this means that more corner cases of the language correctly type-check than before
- Improvement: New
--plainflag to disable syntax highlighting - Improvement: Prelude now provides an umbrella
package.dhallimport- This is primarily for convenience
- See: https://github.com/dhall-lang/dhall-haskell/pull/298
- Improvement: Context is now normalized
- Replace
cryptohashdependency withcryptonite - Increase upper bound on exceptions
- Fix type error in tutorial
1.10.0
- Feature: Records/unions can now have fields/alternatives that are types
- i.e.
{ foo = Text, bar = List }is legal now - See: https://github.com/dhall-lang/dhall-haskell/pull/273
- i.e.
- Feature: New
dhall-replfor interactively evaluating Dhall expressions - Feature: Syntax highlighting
- Feature: BREAKING CHANGE TO THE API:
dhall-formatpreserves field order- This changes the syntax tree to use an
InsOrdHashMapinstead of aMap
- This changes the syntax tree to use an
- BREAKING CHANGE TO THE API: Use Haskell's
Scientifictype- This is fixes the interpreter to correct handle really large/small numbers
- This also allows marshaling into Haskell's
Scientifictype - See: https://github.com/dhall-lang/dhall-haskell/pull/256
- BREAKING CHANGE TO THE API: Remove
system-filepath/system-fileiodependencies- Now the library uses
Prelude.FilePath - See: https://github.com/dhall-lang/dhall-haskell/pull/248
- Now the library uses
- Feature: Labels can now begin with reserved names
- i.e.
List/mapis now a legal label - See: https://github.com/dhall-lang/dhall-haskell/pull/255
- i.e.
- Fix: Rendered labels are now correctly escaped if they are numbers
- Add the instance
Interpret String. - Fix: Custom contexts passed to
typeWithare now checked- This prevents a custom context from triggering an infinite loop
- See: https://github.com/dhall-lang/dhall-haskell/pull/259
1.9.1
dhall-formatnow emits single-quoted strings for multi-line strings- Improved error messages for list elements with the wrong type
- Change
lensdependency tolens-family-core
1.9.0
- Feature: BREAKING CHANGE TO LANGUAGE AND API: Add
constructorskeyword- This new keyword generates constructors from a union type
- See the updated Haskell tutorial for more details
- This means that
constructorsis now a reserved keyword - This adds a new
Constructorsconstructor to theExprtype - See: https://github.com/dhall-lang/dhall-haskell/pull/199
- This new keyword generates constructors from a union type
- Feature: BREAKING CHANGE TO THE API:
dhall-formatpreserves interpolation- This changes the
TextLitconstructor to represent an interpolatedTextliteral - See: https://github.com/dhall-lang/dhall-haskell/pull/220
- This changes the
- Feature: You can now define type synonyms using
let - Feature: Extend valid set of quoted labels
- Performance: Improve startup time when importing files, but not URLs
- Security:
localhost/127.0.0.1imports no longer count as local imports- Specifically: they cannot import environment variables or files
- See: https://github.com/dhall-lang/dhall-haskell/pull/197
- Security: Fix potential type-checking bug
- Fix: BREAKING CHANGE TO API: Improve localization of error messages
- This required fixing the type of
normalize/shift/substto preserve the first type parameter ofExpr(i.e. they no longer deleteNoteconstructors) - A new
denotefunction was added for the explicit purpose of deletingNoteconstructors - See: https://github.com/dhall-lang/dhall-haskell/pull/218
- This required fixing the type of
- Expose
MissingEnvironmentVariableexception type - Add
genericAuto - Add
inputWith - Add
loadWithContext - Add
pair/unit/string/list
1.8.2
- Add
typeWithAfor type-checking customEmbedded values - Fix
dhall{,-*}executables to ignore ambient locale and use UTF8 - Increase upper bound on
tastydependency
1.8.1
dhallexecutable can now format output using--pretty- Improved Unicode suppport on Windows
1.8.0
- BREAKING CHANGE TO LANGUAGE: Add support for import integrity checks
- In practice, the likelihood of this breaking code in the wild is astronomically low
- This would only break code of the form
sha256:aaa...aaa(i.e. a variabled namedsha256with a type annotation for a type with a name 64 characters long drawn from the first 6 characters of the alphabet)
- BUG FIX: Fix parsing of single quotes in single-quoted strings
- BUG FIX: Fix superfluous parentheses introduced by
dhall-format - New
dhall-hashexecutable- This goes hand-in-hand with the added support for integrity checks since the executable lets you compute the current hash of an import
1.7.0
- BREAKING CHANGE TO LANGUAGE: Update parser to match standardized grammar
- Trailing commas and bars no longer supported for union and record literals
- Paths no longer permit commas
- URL grammar is now RFC-compliant
- Environment variables can now be quoted to support full range of POSIX-compliant names
- Text literals support full set of JSON escape sequences (such as
\u2192)
- BREAKING CHANGE TO LANGUAGE: Single quoted strings strip leading newlines
- BUG FIX: Fixed type-checking infinite loops due to non-type-checked variables in context
- BUG FIX: Fixed type-checking bug due to missing context when type-checking certain expressions
- BUG FIX: Fixed type-checking bug due to off-by-one errors in name shadowing logic
- New
dhall-formatexecutable to automatically format code - Performance optimizations to
Natural/foldandList/fold - Improved parsing performance (over 3x faster)
- Union literals can now specify the set value anywhere in the literal
- i.e.
< A : Integer | B = False | C : Text >
- i.e.
- New
Injectinstance for() - Several tutorial fixes and improvements
1.6.0
- BREAKING CHANGE TO THE API: Drop support for GHC 7.*
- BREAKING CHANGE TO THE API: Add support for customizing Dhall import
- This is a breaking change because this changes the type of
loadWith
- This is a breaking change because this changes the type of
- BREAKING CHANGE TO THE API: Add field to
UnboundVariableerror containing - BUG FIX: Fix parsing single quotes in string literals the name of the unbound variable
- Add
List/concatMapto the Prelude - You can now derive
InjectandInterpretfor types with unlabeled fields - Add new instances for
Interpret:[](,)
- Add new instance for
Inject[],Data.Set.Set,Data.Sequence.Seq(,)Int,Word8,Word16,Word32,Word64
- Add
Eqinstance forSrc
1.5.1
- Increase upper bound on
vectorandoptparse-generic
1.5.0
- BREAKING CHANGE: Add list concatenation operator:
(#)- This is a breaking change because it adds a new constructor to the
Exprtype which breaks exhaustive pattern matches
- This is a breaking change because it adds a new constructor to the
- BREAKING CHANGE: Add
Interpretsupport for lazyText- This is a breaking change because it renames
texttostrictText
- This is a breaking change because it renames
- Add
Interpretinstance for decoding (a limited subset of) Dhall functions - Dhall no longer requires Template Haskell to compile
- This helps with cross-compilation
- Add
rawInpututility for decoding a Haskell value from theExprtype - Add
loadWith/normalizeWithutilities for normalizing/importing modules with a custom context - Export
Typeconstructor
1.4.2
- Fix missing
Preludefiles in package archive uploaded to Hackage
1.4.1
- Fix missing
tests/Tutorial.hsmodule in package archive uploaded to Hackage
1.4.0
- BREAKING CHANGE TO THE LANGUAGE AND API: You can now supply custom headers for
URL imports with the new
usingkeyword- This is a breaking change to the language because this adds a new reserved
usingkeyword - This is a breaking change to the API because this adds a new field to the
URLconstructor to store optional custom headers
- This is a breaking change to the language because this adds a new reserved
- BUG FIX:
:is no longer a disallowed path character- This was breaking URL imports with a port
- BUG FIX: If you import a home-anchored path (i.e.
~/foo) and that imports a relative path (like./bar), then the canonical path of the relative import should be home-anchored (i.e.~/bar). However, there was a bug that made lose the home anchor (i.e../foo/bar), which this release fixes likely fail due to no longer being home-anchored (i.e. `./foob - Add support for string interpolation
mergeno longer requires a type annotation if you are merging at least one alternative- Expanded Prelude
./Prelude/Optional/all./Prelude/Optional/any./Prelude/Optional/filter./Prelude/Optional/length./Prelude/Optional/null./Prelude/Text/concatMap./Prelude/Text/concatMapSep./Prelude/Text/concatSep
- Rearrange detailed error messages to put summary information at the bottom of the message
1.3.0
- BREAKING CHANGE TO THE API: Add support for new primitives, specifically:
(//)- Right-biased and shallow record mergeOptional/build(now a built-in in order to support build/fold fusion)Natural/showInteger/showDouble/showNatural/toInteger- These all add new constructors to the
Exprtype, which would break exhaustive pattern matches
- BREAKING CHANGE TO THE LANGUAGE: Imported paths and URLs no longer support
the characters: "()[]{}<>:"
- This reduces the number of cases where you have to add a space after imports
- Note that this does not exclude the
:in the URL scheme (i.e.http://)
- Increase connection timeout for imports
- Variable names now allow the
-character for all but the first character - You can now escape identifiers with backticks
- This lets you name identifiers so that they don't conflict with reserved key words
- This is most useful when converting Dhall to other file formats (like JSON) where you might need to emit a field that conflicts with one of Dhall's reserved keywords
- New
--versionflag for thedhallexecutable
1.2.0
- BREAKING CHANGE: Add support for customizing derived
Interpretinstances- This is a breaking change to the Dhall library API since this changes the
signature of the
Interpretclass by replacing theautomethod with a more generalautoWithmethod. ThisautoWithnow takes anInterpretOptionsargument that lets you customize derived field and constuctor names - In practice user programs that use the common path will be unaffected by this change
- This is not a breaking change to the Dhall language
- This is a breaking change to the Dhall library API since this changes the
signature of the
- BREAKING CHANGE: Type annotations now bind more tightly than lambda
abstraction
-
This is a breaking change to the Dhall language. An expression like this:
λ(x : A) → y : B... used to parenthesized implicitly as:
(λ(x : A) → y) : T... but is now parenthesized implicitly as:
λ(x : A) → (y : T)This is now consistent with Haskell's precedence and also consistent with the precedence of
ListandOptionaltype annotations -
This change affects programs with an expression like this:
-- Assuming that `y : B` λ(x : A) → y : A → BThe above program would type-check before this change but not type-check after this change. You would you need to fix the above program by either changing the type signature to annotate just the type of
ylike this:λ(x : A) → y : B... or by adding explicit parentheses like this:
(λ(x : A) → y) : A → B -
This is not a breaking change to the Dhall library API
-
- BREAKING CHANGE: Add support for importing a path's contents as raw
Textby addingas Textafter the import-
This is a breaking change to the Dhall language
-
This is technically a breaking change, but is extremely unlikely to affect you program. This only changes the behavior of old programs that had an expression of the form:
/some/imported/function as Text... where
/some/imported/functionis an imported function being applied to two arguments, the first of which is a bound variable namedasand the second of which is the typeText -
This is not a breaking change to the Dhall library API
-
- BREAKING CHANGE: Add support for importing environment variables using
env:VARsyntax-
This is a breaking change to the Dhall library API since it adds a new
Pathconstructor -
This also technically a breaking change to the Dhall language but extremely unlikely to affect your program. This only changes the behavior of old programs that had an expression of the form:
env:VAR... where
envwas the name of a bound variable and:VARwas a type annotation without spaces around the type annotation operatorAfter this change the program would be interpreted as an import of the contents for the environment variable named
VAR
-
- BREAKING CHANGE: Support importing paths relative to home directory using
~/some/pathsyntax- This is a breaking change to the Dhall library API since it adds a new
field to the
Fileconstructor indicating whether or not the imported path is relative to the home directory - This is not a breaking change to the Dhall language and the new syntax does not override any old syntax
- This is a breaking change to the Dhall library API since it adds a new
field to the
- Permit trailing commas and bars in record/union syntax
- Improve location information for parsing errors
1.1.0
- BREAKING CHANGE: Non-empty lists no longer require a type annotation
- This is a breaking change to the Haskell library, not the Dhall language
- This change does not break existing Dhall programs
- The
Exprtype was modified in a non-backwards-compatible way
- Add new
exprAparser - Add new
InvalidTypeexception ifinputfails on an invalidType - Improve documentation and tutorial
1.0.2
- Add support for Nix-style "double single-quote" multi-line string literals
- Add
isNormalized - Improve documentation and tutorial
- Build against wider range of
http-clientversions
1.0.1
- Initial release
1.0.0
- Accidental premature upload to Hackage. This release was blacklisted