Created
August 13, 2015 11:13
-
-
Save yoshihiro503/b0b4e6c14882a68f80a5 to your computer and use it in GitHub Desktop.
Coqでもあのニンジャパターンマッチが使えるぜ ref: http://qiita.com/yoshihiro503/items/c83fb2a6e2a6318db108
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Error: Destructing let on this type expects 2 variables. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
let (変数名1, ..., 変数名n) := 式1 in ... |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
match 式1 with | |
| コンストラクタ(変数名1,...,変数名n) => ... | |
end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
let '(x, y, z) := (1, 2, 3) in | |
... |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment