Commit Graph

95 Commits

Author SHA1 Message Date
Gabriel Gonzalez 4c7b75b503
Version 1.27.0 → 1.28.0 (#1575) 2019-12-05 19:28:39 -08:00
Gabriel Gonzalez 1349a50f91 Add `Integer/{clamp,negate}` built-ins (#1486)
... as standardized in https://github.com/dhall-lang/dhall-lang/pull/780
2019-10-29 17:21:00 +00:00
Gabriel Gonzalez 7b414d9846
Version 1.26.1 → 1.27.0 (#1428) 2019-10-20 07:00:43 -07:00
Ehmry - 48ca2d2424 Optionally pass Nixpkgs through entry functions (#1409)
The "builtins.fetchTarball" function is not available in some restricted
environments such as build jobs of the latest Hydra. Make it possible to
pass nixpkgs and nixpkgsStaticLinux when evaulating default.nix and
release.nix to avoid importing them internally. This does not change the
result of evaulation if no parameters are passed.
2019-10-17 19:06:21 -07:00
Patrick Mylund Nielsen c92c6bbc22
Eta: Remove YAML FFI code and disable dhall-nix build 2019-10-15 06:22:49 -04:00
Gabriel Gonzalez 17fb0e3c46
100% haddock coverage (#1416)
This updates the `dhall` package to have 100% haddock coverage and
also updates CI to enforce this going forward.

This also includes a change to deprecate the `X` type synonym, which
I noticed along the way
2019-10-13 22:22:39 -07:00
Gabriel Gonzalez 4b8b8cd730
Add new record completion operator (#1375)
... as standardized in https://github.com/dhall-lang/dhall-lang/pull/767
2019-10-11 08:26:51 -07:00
Simon Jakobi 7c91dd5f48 Fix Expr's Eq instance via a newtype wrapper for Doubles (#1347)
See the haddocks in Dhall.Core for details.

Fixes #1341.
2019-09-28 14:56:37 +00:00
Simon Jakobi b556a65644 Handle --version consistently (#1334)
* dhall --version

* dhall-to-bash --version

* dhall-to-nix --version

* dhall-lsp-server --version
2019-09-22 03:55:26 +00:00
Gabriel Gonzalez 65710954cf
Version 1.25.0 → 1.26.0 (#1286) 2019-09-11 19:37:25 -07:00
Gabriel Gonzalez 96921f03ab
Fix `dhall format` to preserve `let` comments (#1273)
Related to https://github.com/dhall-lang/dhall-haskell/issues/145

Note that this also refactors `Let` to use `Binding` in order
to avoid having to duplicate `Src`-related fields in two
places.
2019-09-04 23:41:44 -05:00
Simon Jakobi 72fd2ac983
Treat multi-lets as syntactic sugar (#1242)
Closes #1185.

This mostly reverts "Add support for multi-`let` (#675)" /
8a5bfaa3b9.

Also:

* Add fields for Src
  This is useful for to make 'Note's less noisy during debugging:

      first srcText expr
2019-08-31 18:31:24 +02:00
Ollie Charles 4a93c255db Remove Dhall.X and replace with Data.Void (#1172)
* Remove Dhall.X and replace with Data.Void

This commit removes the Dhall.X module and the Dhall.X.X type,
preferring the use of Data.Void.Void. As I'm sure a lot of people are
actually using X, I've added a type-alias type X = Void. However,
pattern matching on X would be a breaking change.

Fixes #1120.

* Restore unsafeCoerce

* Fix regression

* Unused

* Reorganise exports

* Fix dhall-nix

* Another fix

* Fix Dhall.LSP.Backend.Typing

* Fix dhall-bash
2019-08-05 13:00:59 +00:00
Gabriel Gonzalez 7f2f57f975
Add support for dependent types (#1164) 2019-08-03 21:38:01 -07:00
Ollie Charles 1b683295fc Implement Natural/subtract (#1133)
* Implement Natural/truncatedSubtract

* Restore commented out code

* Add pretty printing for Natural/truncatedSubtract

* Flip the order of the arguments

* truncatedSubtract -> subtract

* Whitespace

* Whitespace

* Whitespace

* Whitespace

* Remove a try

* Fix Core.hs

* Add a case in Arbitrary (Expr s a)

* Fix Dhall.JSON

* lift2 -> lift0

* Update Dhall.Diff

* Add extra reduction rules

* Fix

* Update Core.hs

* Update dhall-lang submodule

* Updated dhall-lang

* Try rolling back the dhall-lang revision

* Correct isNormalized

* Add more isNormalized rules

* Update dhall-nix
2019-08-02 00:12:43 +00:00
Javier Neira 4d0058b71d Use ghc-8.6.5 in default stack.yaml and make appveyor use it (#1182)
* Make it no buildable in windows as suggested by @sjakobi

* Use last lts resolver for ghc-8.6.5

* Remove unused stack yaml file

* Use default stack yaml
2019-08-01 13:01:16 +00:00
Simon Jakobi 42d80b057d
Include dhall-nix in stack and cabal project configs (#1178)
Note that `dhall-nix` cannot be built on Windows due to its transitive
dependency on the `unix` package.

Also:

* Nix: Enable `-Werror` for `dhall-nix`

* Add support for `toMap` in `dhall-nix`:

    \(x : { a : Bool }) -> toMap x

is translated as

    x:
      (kvs:
        map (k:
          {
            mapKey = k;
            mapValue = builtins.getAttr k kvs;
            }) (builtins.attrNames kvs)) x
2019-07-31 18:24:15 +02:00
Simon Jakobi beb1e7ba6f
Remove old union literal syntax (#1176)
…as standardized in https://github.com/dhall-lang/dhall-lang/pull/573.

Fixes #1175.
2019-07-31 04:44:36 +02:00
Gabriel Gonzalez d45f3ec46b
Version 1.24.0 → 1.25.0 (#1156) 2019-07-28 21:46:32 -07:00
Simon Jakobi b2cbc8227f Remove usage of legacy Optional syntax (#1091)
* Remove usage of legacy Optional syntax

* Dhall.JSON: Use multilet in examples

* Update dhall-json/src/Dhall/JSON.hs

Co-Authored-By: Gabriel Gonzalez <Gabriel439@gmail.com>

* Update dhall-json/src/Dhall/JSON.hs

Co-Authored-By: Gabriel Gonzalez <Gabriel439@gmail.com>

* Update dhall-json/src/Dhall/JSON.hs

Co-Authored-By: Gabriel Gonzalez <Gabriel439@gmail.com>

* Update dhall-nix/src/Dhall/Nix.hs

Co-Authored-By: Gabriel Gonzalez <Gabriel439@gmail.com>

* Update dhall-nix/src/Dhall/Nix.hs

Co-Authored-By: Gabriel Gonzalez <Gabriel439@gmail.com>

* Revert changes to travis.yml

* Lint travis.dhall
2019-07-14 18:36:41 +00:00
Gabriel Gonzalez 154d1c52cf
Remove support for old-style `List`-like `Optional` literals (#1002)
... as standardized in https://github.com/dhall-lang/dhall-lang/pull/572
2019-06-13 17:59:49 -07:00
Gabriel Gonzalez d77a9f4e43
Restore `dhall-nix` to build against Hackage (#1000)
Now that `hnix-0.6.1` is out `dhall-nix` can be built against recent
versions of Hackage packages and will be uploaded as part of the
next release
2019-06-10 08:29:05 -07:00
Gabriel Gonzalez fc5b382238
Version 1.23.0 → 1.24.0 (#984) 2019-06-06 17:14:43 -07:00
Gabriel Gonzalez 3c08c627e8
Support projection by record type (#958)
... as standardized in https://github.com/dhall-lang/dhall-lang/pull/499
2019-05-27 20:54:42 -07:00
Gabriel Gonzalez bf4349ef7a
Version 1.22.0 → 1.23.0 (#943) 2019-05-11 13:03:42 -07:00
Gabriel Gonzalez 44a2750ca0
Explain use case for `dhall-to-nix` (#913)
Fixes https://github.com/dhall-lang/dhall-haskell/issues/902
2019-04-27 21:10:02 -07:00
Gabriel Gonzalez f7fecda09d
Version 1.21.0 → 1.22.0 (#910) 2019-04-27 20:17:34 -07:00
Ollie Charles d3d7baf3e5
dhall-nix: Fix field-based union access (#907)
Fixes #906.

This adds new translation rules:

* <Foo : {} | Bar>.Foo => x: { Bar, Foo }: Foo x

* <Foo : {} | Bar>.Foo {=} => { Bar, Foo }: Foo {}

* <Foo : {} | Bar>.Bar => { Bar, Foo }: Bar
2019-04-27 11:17:01 +01:00
Gabriel Gonzalez f4542d5bc5
Integrate `dhall-nix` into CI (#887) 2019-04-11 09:16:43 -07:00
Profpatsch 6c38bd89ea Update to dhall > 1.19 (#19)
Some things have changed in the dhall expression tree:

- `let` bindings now take a list of bindings
- `Some` and `None` were introduced
- `Text/show` was added

Additionally, dhall switched to an internal `Map` module instead of
`HashMap.Strict.InsOrd`.

Closes: https://github.com/dhall-lang/dhall-nix/issues/18
2019-04-09 06:59:01 -07:00
Gabriel Gonzalez a2860c8761 Add correct version of `cabal-install` to `nix-shell` (#16) 2018-08-31 08:31:47 -07:00
Gabriel Gonzalez 9c952a80de Version 1.1.5 → 1.1.6 (#15) 2018-08-31 08:23:04 -07:00
Gabriel Gonzalez 382613da5d Build against `dhall-1.17.0` (#14) 2018-08-31 08:14:04 -07:00
Gabriel Gonzalez 7e5d14a776 Upgrade to more recent Nixpkgs (#12) 2018-08-11 15:40:33 -05:00
Gabriel Gonzalez eb6d561503 Build against `dhall-1.16.1` (#11) 2018-07-22 00:27:39 -07:00
Gabriel Gonzalez 0ae0367927 Version 1.1.4 → 1.1.5 (#6) 2018-06-28 22:01:43 -07:00
Gabriel Gonzalez f67b8cc171 Build against `dhall-1.5.0` (#5) 2018-06-28 21:56:58 -07:00
Gabriel Gonzalez 16dc491dcf Version 1.1.3 → 1.1.4 (#4) 2018-05-19 10:46:07 -07:00
Gabriel Gonzalez 68871355d1 Build against `dhall-1.14.0` (#3) 2018-05-19 10:39:00 -07:00
Gabriel Gonzalez 41e74ee9da Pin `nixpkgs` 2018-05-01 08:45:39 -07:00
Gabriel Gonzalez 2f7678a67a Version 1.1.2 → 1.1.3 2018-04-28 08:07:35 -07:00
Gabriel Gonzalez 559e6fd13e Build against `dhall-1.13.0` 2018-04-28 08:06:18 -07:00
Gabriel Gonzalez 354ab1491f Version 1.1.1 → 1.1.2 2018-03-24 10:16:49 -07:00
Gabriel Gonzalez 14ebc0b990 Build against `dhall-1.12.0` 2018-03-24 10:15:45 -07:00
Gabriel Gonzalez c2b8c2dedb Increase upper bound on `hnix` 2018-03-12 08:13:15 -07:00
Gabriel Gonzalez c441f7cca7 Version 1.1.0 → 1.1.1 2018-03-08 20:31:55 -08:00
Gabriel Gonzalez 79447ec5ee Build against `dhall-1.11.0` 2018-03-08 20:31:26 -08:00
Gabriel Gonzalez 0d3c572550 Version 1.0.10 → 1.1.0 2018-02-23 20:39:51 -08:00
Gabriel Gonzalez 200dd73b15 Increase upper bound on `optparse-generic` 2018-02-23 20:37:44 -08:00
Gabriel Gonzalez 534313af18 Build against `dhall-1.10.0` 2018-02-23 20:35:34 -08:00