冒号大于符号在coq中是什么意思

what does the colon greater than sign mean in coq

例如

Record posreal : Type := mkposreal {pos :> R; cond_pos : 0 < pos}.

“:>”是什么意思? 我希望这不是重复的,但符号很难搜索。

在这种特殊情况下,它将 posreal 记录中的强制转换插入其字段 pos。这意味着在大多数情况下,您可以将 posreal 用于 R

尝试:

Definition idR (x : R) := x.
Variable (r : posreal).
Compute (idR r).

https://coq.inria.fr/refman/Reference-Manual021.html#Coercions-and-records