fosskers / cl-transducers

Transducers: Ergonomic, efficient data processing
https://fosskers.github.io/cl-transducers/
GNU Lesser General Public License v3.0
100 stars 4 forks source link

`max` requires at least 1 argument, not 2 #1

Closed Hexstream closed 1 year ago

Hexstream commented 1 year ago

Oh, so this repo is also on GitHub... Good thing, because I had just given up on reporting this. ;P

So, your documentation states:

Other functions like max cannot be used as-is as reducers since they require at least 2 arguments.

Note that max requires at least 1 argument, not 2.

fosskers commented 1 year ago

Ah, thank you! I will fix this documentation error.

Note also that the main tracker for these Transducer repos can be found here: https://todo.sr.ht/~fosskers/transducers Apologies for not making it clearer how to report issues.

But for the time being I will also push things here and respond to issues!

Hexstream commented 1 year ago

Using any code hosting platform other than GitHub is the death of usability as far as I'm concerned, even if the UI were to be identical. (But especially if it's different.)

fosskers commented 1 year ago

There are plenty of alternate source forges out there, each with their benefits and drawbacks. You're of course free to use what you consider best.

With regards to the original documentation issue: the problem is that the built-in max/min can't be called with zero arguments, which is a requirement of reducer functions. Note that (as mentioned in that docstring) that + and * do work this way out-of-the-box, so fold is not needed.

Hexstream commented 1 year ago

There are plenty of alternate source forges out there

Which is actually a strong argument against their use, as it's unrealistic to expect users to create an account on multiple obscure alternative services.

each with their benefits and drawbacks

I'm constantly amazed that not everyone realizes that the drawback of not using GitHub is nearly impossible to overcome.

You're of course free to use what you consider best.

It's more than a "consideration", it's usable VS unusable. ;P

With regards to the original documentation issue [...]

I know, but the documentation still shouldn't be inaccurate or misleading.

fosskers commented 1 year ago

I've fixed the documentation issue in both the README and the docstring. Thanks again for the report.

Hexstream commented 1 year ago

Awesome, thanks!