lib.fixedPoints.toExtension: Improve type
This makes the type more informative and general - closer to how the function behaves, particularly in isolation. Co-authored-by: Yueh-Shun Li <shamrocklee@posteo.net>
This commit is contained in:
committed by
Yueh-Shun Li
parent
30809ccecd
commit
2937899bef
@@ -463,8 +463,17 @@ rec {
|
||||
# Type
|
||||
|
||||
```
|
||||
toExtension ::: (a | a -> a | a -> a -> a) -> a -> a -> a
|
||||
a = AttrSet & !Function
|
||||
toExtension ::
|
||||
b' -> Any -> Any -> b'
|
||||
or
|
||||
toExtension ::
|
||||
(a -> b') -> Any -> a -> b'
|
||||
or
|
||||
toExtension ::
|
||||
(a -> a -> b) -> a -> a -> b
|
||||
where b' = ! Callable
|
||||
|
||||
Set a = b = b' = AttrSet & ! Callable to make toExtension return an extending function.
|
||||
```
|
||||
|
||||
# Examples
|
||||
|
||||
Reference in New Issue
Block a user