-
Notifications
You must be signed in to change notification settings - Fork 377
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
Define "checked" in Terminology Section #210
Comments
Any kind of inspection of the value, for example |
We should re-iterate what that actually means in the spec. A lot of libraries don't adhere to that part of the spec, so some clarity might be very useful here. |
@SimonRichardson can you give an example from a library that doesn't conform? I'm struggling to understand how the prescriptive "Don't use the kinds of things @Avaq pointed out" is more clear than just the signature itself.
I was confused because yeah, it needs a I'm probably wrong on this, but I feel like:
I don't know. I just found it confusing. Maybe it's just me. |
@EvanBurchard I think it's to avoid implementations like MyFunctor.prototype.map = f =>
MyFunctor.of(f(typeof this.value === 'number' ? this.value + 1 : this.value)) (Though in reality things like null checking are more common) |
Exactly what @rjmk shown, I've seen this in the wild a couple of times (I need to keep a list of this stuff tbh!). |
Example usage:
No parts of f's return value should be checked.
The text was updated successfully, but these errors were encountered: