You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Uniformize semantics of :> in class after deprecation phase of rocq-prover#16230
This ends the deprecation phases of
rocq-prover#16230 and
rocq-prover#15802
that introduced :: instead of :> for subclasses in Class declarations.
Now :> means coercion in all record declarations (including typeclasses).
This command has no effect when used on a typeclass.
344
343
345
-
.. _warn-future-coercion-class-field:
346
-
347
-
.. warn:: A coercion will be introduced instead of an instance in future versions when using ':>' in 'Class' declarations. Replace ':>' with '::' (or use '#[global] Existing Instance field.' for compatibility with Coq < 8.17).
348
-
349
-
In future versions, :g:`:>` in the :n:`@record_definition` or
350
-
:n:`@constructor` will declare a :ref:`coercion<coercions>`, as
351
-
it does for other :cmd:`Record` commands. To eliminate the warning, use
352
-
:g:`::` instead.
353
-
354
344
.. warn:: Ignored instance declaration for “@ident”: “@term” is not a class
355
345
356
-
Using the ``::`` (or deprecated ``:>``) syntax in the :n:`@record_definition`
346
+
Using the ``::`` syntax in the :n:`@record_definition`
357
347
or :n:`@constructor` with a right-hand-side that
358
348
is not itself a Class has no effect (apart from emitting this warning).
strbrk "A coercion will be introduced instead of an instance in future versions when using ':>' in 'Class' declarations. "
700
-
++ strbrk "Replace ':>' with '::' (or use '#[global] Existing Instance field.' for compatibility with Coq < 8.18). Beware that the default locality for '::' is #[export], as opposed to #[global] for ':>' currently."
701
-
++ strbrk (if definitional then" Add an explicit #[global] attribute if you need to keep the current behavior. For example: \"Class foo := #[global] baz :: bar.\""
702
-
else" Add an explicit #[global] attribute to the field if you need to keep the current behavior. For example: \"Class foo := { #[global] field :: bar }.\""))
703
-
704
684
letcheck_proj_flagskindrf=
705
685
letopenVernacexprin
706
686
let pf_coercion, pf_reversible =
707
687
match rf.rf_coercion with
708
-
(* replace "kind_class kind = NotClass" with true after deprecation phase *)
0 commit comments