Closed kevinresol closed 6 years ago
I just played around a little and I think https://github.com/haxetink/tink_streams/commit/5262af1c6a06c3b09d5817e93a0aeb85a39cc7d7 might improve it quite a bit. Can you confirm?
This seems worked. I wonder what magic has been done.
It's basically this again: https://github.com/haxetink/tink_core/issues/59
To be able to write return Resume;
, I had wrapped the function in { apply: ... }
, so that the compiler must infer the function bottom up and then uses the implicit cast. But because of that, the argument type becomes unknown.
So this code:
gives
Unknown<0>
Any idea how to make it correctly infer the type?