1
我剛纔看到有人在勒柯克在一個陌生的語法定義的感應式,像這樣:Coq歸納定義中的``和`&'是什麼?
Inductive nat_tree : Type :=
| NatLeaf
| NatNode of color & nat_tree & nat & nat_tree.
我習慣的樣子this語法:
Inductive ident : sort :=
ident1 : type1
| …
| identn : typen
誰能解釋一下什麼是新的句法?
順便說一句,這是來自ssrflect教程。我想知道這是否是一個ssr補充。
我的猜測是它的使用是因爲它很好地模仿了OCaml變體類型的語法。在思考之前從未看過它。 – gallais