Owen Shepherd
Owen Shepherd
I'm going to try to rebase this branch. It's quite out of date, and is a prerequisite for https://github.com/haskell/haskell-language-server/pull/3749
@mixphix yes, I've encountered and used `ListT.unfoldM`. It feels like base has something missing, with `foldr` and `unfoldr`, and `foldM` but no dual.
@mixphix to some extent I agree with you, but the vast majority of functions in (say) Data.List are user-definable, yet we, as a community, have decided that some combination of...
@ysangkok I don't think `Foldable1` is the place for `unfoldM`. Unfolds cannot be expressed as folds (okay, if they can, I wish to remain ignorant...), and we're implementing concrete unfolds,...
@cdsmith re: `a -> m (Maybe a) -> m (NonEmpty a)` > That seems wrong to me, since you very well might need to use functionality of the monad to...
One reservation I have is that this is a new type of pattern. I wanted to introduce the dual of `foldM`, but `generateList` isn't quite it. In fact, you could...
It sounds we agree to the dual pairings of (foldM/unfoldM) and (traverse_/generateList). It's unfortunate from an ergonomic perspective that `traverse_` and `generateList` have unrelated names, that don't suggest they are...
Hmmm, I ran a few tests, and the flake format is pretty strict. It (and the input attr) has to be a literal set, it can't be imported, or used...
Using niv to implement `nix flake lock --update-input foo` would be pretty easy though. You shouldn't need to read or edit nix, right? Just JSON? Actually you could totally cheat...
@nmattia Ah, yes, you're right. We would need to read the `flake.nix`. FWIW I think later versions of `nix` actually have a `nix flake update ` command, so maybe we...