You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
A.k.a. the function that detects and breaks recursion cycles. Related to Haskell's fix, but not the same thing.
Minimal TODO for a release-worthy version:
DONE: Allow kwargs for f, everything else does.
DONE: Make the implementation thread-safe, almost everything else is.
DONE: Move unit tests to a new separate module unpythonic/test/test_fix.py.
Investigate (but not necessarily resolve yet) whether we can reorganize things so we could guarantee to call bottom at most once. (Currently it's at least once, at most twice.)
Document it in README, including credits for the original idea (Matthew Might) and initial Python implementation (Per Vognsen).
The text was updated successfully, but these errors were encountered:
DONE in 9ddd466: Fix the docstring, it currently says fix is not thread-safe, which is no longer true.
DONE in 8bb8fd9 (though only visited needed it): Unwind-protect the changes to visited and cache by using a finally block. Currently, if f raises, garbage is left in the state.
A.k.a. the function that detects and breaks recursion cycles. Related to Haskell's
fix
, but not the same thing.Minimal TODO for a release-worthy version:
f
, everything else does.unpythonic/test/test_fix.py
.bottom
at most once. (Currently it's at least once, at most twice.)The text was updated successfully, but these errors were encountered: