
29 Feb
2016
29 Feb
'16
5:11 p.m.
Hello, Have you tried using the package https://hackage.haskell.org/package/reflection ? It won't directly help you with: fromN :: forall n. KnownNat n => Integer -> NatString n but it does provide a function: reifyNat :: forall r. Integer -> (forall n. KnownNat n => Proxy n -> r) -> r which could help you if you'd manage to turn your function inside out, so that the `n` parameter doesn't escape the callback. Best regards, Marcin Mrotek