darcs

Patch 2281 TreeMonad refactors

Title TreeMonad refactors
Superseder Nosy List bfrk
Related Issues
Status accepted Assigned To
Milestone

Created on 2023-02-22.20:52:36 by bfrk, last changed 2023-07-15.22:36:31 by ganesh.

Files
File name Status Uploaded Type Edit Remove
clarify-how-treemonad-gets-parameterized.dpatch bfrk, 2023-02-22.20:52:35 application/x-darcs-patch
patch-preview.txt bfrk, 2023-02-22.20:52:35 text/x-darcs-patch
patch-preview.txt bfrk, 2023-07-15.19:28:17 text/x-darcs-patch
slightly-re_word-haddocks-in-darcs_util_tree_monad.dpatch bfrk, 2023-07-15.19:28:18 application/x-darcs-patch
See mailing list archives for discussion on individual patches.
Messages
msg23121 (view) Author: bfrk Date: 2023-02-22.20:52:35
3 patches for repository http://darcs.net/screened:

patch 2ba29366aa0e742c0842f7c80f433426da730785
Author: Ben Franksen <ben.franksen@online.de>
Date:   Thu Oct 28 09:30:24 CEST 2021
  * clarify how TreeMonad gets parameterized

  This adds two type synonyms HashItem and DumpItem, renames the corresponding
  members of TreeEnv, and improves the module documentation.

patch dba0c4c1158296a936d69392afd710db4ed9103d
Author: Ben Franksen <ben.franksen@online.de>
Date:   Sun Aug  7 13:10:41 CEST 2022
  * fix docs for Darcs.Util.Tree.Monad.flushItem

patch 0ca5344f6de46f5f93034380fce6f84f57460daf
Author: Ben Franksen <ben.franksen@online.de>
Date:   Thu Oct 28 12:35:36 CEST 2021
  * simplify the TreeMonad configuration

  This remove the hashItem configuration procedure for TreeMonad. Instead,
  dumpItem is now supposed to also update the item's hash and expand stubs.
  This reduces repeated recursive tree traversals and avoids partial
  functions. Furthermore, dumpItem now runs in the base monad.
Attachments
msg23575 (view) Author: ganesh Date: 2023-07-15.10:49:03
Incremental review

>   * clarify how TreeMonad gets parameterized

Looks good, one tiny comment:

> This module provides the readily configured 'virtualTreeIO' that never
> writes any changes, but may trigger filesystem reads as appropriate.

If I understand this sentence correctly this should be "ready 
configured" (meaning already or previously configured with hashItem and 
dumpItem) rather than "readily configured" (meaning easily configured).

>  * fix docs for Darcs.Util.Tree.Monad.flushItem

Looks good, again one tiny comment:

> --- | Flush a single item to disk. This is the only procedure that uses
> --- 'dumpItem' and 'hashItem' from the environment.
> +-- | Flush a single item to disk. This is the only procedure that uses the
> +-- Reader part of the environment (the procedure of type @'DumpItem' m@).

Maybe "directly uses"?
msg23577 (view) Author: ganesh Date: 2023-07-15.12:16:27
>   * simplify the TreeMonad configuration

OK
msg23578 (view) Author: bfrk Date: 2023-07-15.19:28:18
> If I understand this sentence correctly this should be "ready
> configured" (meaning already or previously configured with hashItem and
> dumpItem) rather than "readily configured" (meaning easily configured).

Good point. I'll go with "pre-configured", that the clearest I think.

>> [...] This is the only procedure that uses the
>> Reader part of the environment (the procedure of type @'DumpItem' m@).
> 
> Maybe "directly uses"?

Yep, that's what I meant to say.

1 patch for repository http://darcs.net/screened:

patch 5e85cfab8952258da0cb21c770b24560c9ad1d31
Author: Ben Franksen <ben.franksen@online.de>
Date:   Sat Jul 15 21:19:06 CEST 2023
  * slightly re-word haddocks in Darcs.Util.Tree.Monad
Attachments
History
Date User Action Args
2023-02-22 20:52:36bfrkcreate
2023-02-22 20:53:06bfrksetstatus: needs-screening -> needs-review
2023-07-15 10:49:03ganeshsetmessages: + msg23575
2023-07-15 12:16:28ganeshsetmessages: + msg23577
2023-07-15 19:28:19bfrksetfiles: + patch-preview.txt, slightly-re_word-haddocks-in-darcs_util_tree_monad.dpatch
messages: + msg23578
2023-07-15 21:44:31ganeshsetstatus: needs-review -> accepted-pending-tests
2023-07-15 22:36:31ganeshsetstatus: accepted-pending-tests -> accepted