Commit dc59467
committed
Change types to work w/o explicit type parameter
Previously, the type parameter of the kind of node that was checked for
needed to be passed.
This node kind had to be matched by the given runtime `test`.
At that point, it was known that node would be of that kind.
Now, the given runtime test is used in the type system to narrow the
given `node` value down.
This means that the types can become much simpler.
Instead of `AssertAnything` and `AssertPredicate`, use the new `Check`.
Instead of `TestFunctionAnything` and `TestFunctionPredicate`, use
`TestFunction`.
Instead of `PredicateTest`, use `Test`.1 parent cf2dacf commit dc59467
File tree
8 files changed
+562
-644
lines changed- lib
- test
8 files changed
+562
-644
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
| 2 | + | |
2 | 3 | | |
3 | | - | |
4 | | - | |
5 | | - | |
6 | | - | |
7 | | - | |
8 | | - | |
9 | | - | |
10 | | - | |
11 | | - | |
12 | | - | |
13 | | - | |
14 | | - | |
15 | | - | |
16 | | - | |
17 | | - | |
18 | | - | |
19 | | - | |
| 4 | + | |
20 | 5 | | |
21 | 6 | | |
22 | 7 | | |
0 commit comments