cicada-solo icon indicating copy to clipboard operation
cicada-solo copied to clipboard

[feature] equivalence

Open xieyuheng opened this issue 3 years ago • 3 comments

Problem:

We need a built-in type for equivalence.

Solution 1:

Implement "the little typer"-like Equal:

  • Equal
  • Replace
  • Refl
  • Same

xieyuheng avatar Sep 13 '22 10:09 xieyuheng

I highly recommend a modern identity type (beyond jmeq or mltt id). Quotients and funExt are essential.

ice1000 avatar Sep 13 '22 14:09 ice1000

Solution 2:

Implement a modern identity type.

(Maybe @ice1000 can suggest something (papers, books, talks, lectures) where we can learn from.)

xieyuheng avatar Sep 13 '22 14:09 xieyuheng

I suggest observational equality by McBride or cubical extension type (either cartesian or de morgan)

ice1000 avatar Sep 13 '22 16:09 ice1000

Solution 1 implemented: https://github.com/cicada-lang/cicada/commit/86e60a30f2e1eafe8876e0cabbd0d71279fc9515

We will explore modern identity type in another issue.

xieyuheng avatar Oct 06 '22 20:10 xieyuheng

  • https://github.com/cicada-lang/cicada/discussions/110

xieyuheng avatar Oct 06 '22 20:10 xieyuheng