lci icon indicating copy to clipboard operation
lci copied to clipboard

Scott encoding

Open suhr opened this issue 2 years ago • 2 comments

It would be great to have a Scott encoding support for numbers and lists, as an alternative to Church encoding.

suhr avatar Dec 25 '21 20:12 suhr

In reply to https://github.com/chatziko/lci/issues/11#issue-1088652802

It would be great to have a Scott encoding support for numbers and lists, as an alternative to Church encoding.

From what I see, there is support for Scott numbers, or am I missing something of your point?

https://github.com/chatziko/lci/blob/2deb0d4de73d109bd1f96bbf5ea67eee627df7ef/src/.lcirc#L117-L144

ifrh avatar Mar 24 '22 14:03 ifrh

Oh, cool. Are lists also Scott encoded? Also, does it works for pretty-printing too?

suhr avatar Mar 24 '22 16:03 suhr