Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove old union literal syntax #1176

Merged
merged 9 commits into from
Jul 31, 2019
Merged

Remove old union literal syntax #1176

merged 9 commits into from
Jul 31, 2019

Conversation

sjakobi
Copy link
Collaborator

@sjakobi sjakobi commented Jul 30, 2019

…as standardized in dhall-lang/dhall-lang#573.

Fixes #1175.

TODO:

  • Complete parser changes (mostly names)
  • Fix docs for dhall-json
  • Fix Dhall.Tutorial and the tutorial tests
  • Fix error messages in Dhall.TypeCheck
  • Remove any other usage of the old syntax
  • Update the "Issue Improve parser performance #108" benchmark

Dhall.Tutorial itself was already using the modern union syntax.

The unions2 testcase seemed to use some pre-constructors style, so
I removed it. The same functionality was covered by the unions3 test.
@@ -33,7 +33,6 @@ tests =
, Test.Tasty.testGroup "Unions"
[ example 0 "./tests/tutorial/unions0A.dhall" "./tests/tutorial/unions0B.dhall"
, example 1 "./tests/tutorial/unions1A.dhall" "./tests/tutorial/unions1B.dhall"
, example 2 "./tests/tutorial/unions2A.dhall" "./tests/tutorial/unions2B.dhall"
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How come BTW that we have tests for the tutorial both here and in https://github.com/dhall-lang/dhall-lang/tree/master/tests/normalization/success/haskell-tutorial?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No good reason 🙂

@sjakobi sjakobi changed the title WIP: Remove old union literal syntax Remove old union literal syntax Jul 30, 2019
@sjakobi
Copy link
Collaborator Author

sjakobi commented Jul 30, 2019

I discovered that the issue108 benchmark was broken mostly by chance. That makes me wonder if any other benchmarks are broken too…

@sjakobi
Copy link
Collaborator Author

sjakobi commented Jul 30, 2019

I also wonder why dhall/benchmark/examples/issue108.dhall.bin is now 110% larger. I should probably look into this!

@sjakobi
Copy link
Collaborator Author

sjakobi commented Jul 31, 2019

I also wonder why dhall/benchmark/examples/issue108.dhall.bin is now 110% larger. I should probably look into this!

Actually it's just a 10% size increase. Nothing to worry about.

@sjakobi
Copy link
Collaborator Author

sjakobi commented Jul 31, 2019

Hydra complains about some breakage in dhall-nix. Is it intentional that dhall-nix isn't included in the stack.yaml (and the cabal.project)?

@Gabriella439
Copy link
Collaborator

@sjakobi: I don't think there is any reason why stack doesn't build dhall-nix. Most likely I just forgot to add it when merging dhall-nix into this repository

@sjakobi sjakobi merged commit beb1e7b into master Jul 31, 2019
@sjakobi sjakobi deleted the 1175-old-union-literals branch July 31, 2019 02:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Implement "Remove union literals from the language"
2 participants