Skip to content

Add to-directory-tree related definitions#1306

Merged
Gabriella439 merged 25 commits intodhall-lang:masterfrom
mmhat:to-directory-tree
Jan 26, 2023
Merged

Add to-directory-tree related definitions#1306
Gabriella439 merged 25 commits intodhall-lang:masterfrom
mmhat:to-directory-tree

Conversation

@mmhat
Copy link
Copy Markdown
Collaborator

@mmhat mmhat commented Sep 21, 2022

These definitions migth be helpful when one uses the fixpoint directory tree representation which got added recently to the Haskell implementation in dhall-lang/dhall-haskell#2437.

@mmhat mmhat force-pushed the to-directory-tree branch from 5255c02 to cf032d0 Compare January 11, 2023 14:37
@mmhat mmhat marked this pull request as ready for review January 11, 2023 14:55
@mmhat
Copy link
Copy Markdown
Collaborator Author

mmhat commented Jan 11, 2023

This is the first draft implementation of the types and functions related to the new to-directory-tree feature. Some of those are basic, some of those proved to be useful to me in my setup and for some I simply assume that they could be useful.
Anyway, I'd like to have some feedback if something is missing or something is too specific to be included in the Prelude.

Pinging @Gabriella439 since she proposed those additions in dhall-lang/dhall-haskell#2437 (comment).

@@ -0,0 +1,71 @@
{- | @toModeWith x m@ converts some fields of a `Mask` @m@ to a `Mode`: If the
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

What is the motivation for the toModeWith and toAccessWith functions? Could you add some additional test cases showing some intended use cases?

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

I added a motivating use case and some more examples to toModeWith. I included a pointer to that in the documentation of toAccessWith. I hope that helps?

@mmhat mmhat requested a review from Gabriella439 January 18, 2023 14:04
Copy link
Copy Markdown
Contributor

@Gabriella439 Gabriella439 left a comment

Choose a reason for hiding this comment

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

Just one last suggestion. Otherwise, this looks good

@mmhat
Copy link
Copy Markdown
Collaborator Author

mmhat commented Jan 26, 2023

@Gabriella439 I fixed the dhall-docs comments and if there is nothing else to do this PR can be merged.

@Gabriella439 Gabriella439 merged commit da6066c into dhall-lang:master Jan 26, 2023
@mmhat mmhat deleted the to-directory-tree branch January 26, 2023 19:25
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.

2 participants