Closed rockymadden closed 5 years ago
@davidchambers In the scenario provided, there would be no reason to do so (other than illustration of the reported issue). In a real world scenario, I might be using Fluture, custom types, types from sanctuary-def, and such in my environment.
Right now, I share the same environment between sanctuary-def and sanctuary.
I'm curious as to why you augment $.env
rather than S.env
.
Is it reasonable for Sanctuary functions to rely on types included in S.env
but not in $.env
?
Interesting. There is no specific reason I did it that way besides assuming it didn't matter. However, I do see what you are saying and some other potential benefits as well (i.e. better perf). Let me invert and touch base.
Yep, this did indeed do the trick. Thank you, kindly, for that tidbit.
You're welcome, Rocky. :)
When using
sanctuary
withcheckTypes
set to true and the environment set to a barebonessanctuary-def
environment, some functions throw type errors with valid usage. These include, but may not be limited to:flip
compose
Ref: https://repl.it/@rockymadden/break-sanctuary-flip
P.S. I acknowledge this might be a
sanctuary-def
bug, but observing the behavior here insanctuary
I thought I'd add here off-the-cuff.