products/Sources/formale Sprachen/Coq/test-suite/bugs/closed image not shown  

Quellcode-Bibliothek

© Kompilation durch diese Firma

[Weder Korrektheit noch Funktionsfähigkeit der Software werden zugesichert.]

Datei: bug_9508.v   Sprache: Coq

Original von: Coq©

Set Implicit Arguments.
Unset Strict Implicit.

Module OK.
Record A := mkA {
  T : Type;
  P : T -> bool;
}.

About P. (* Argument a is implicit *)
Check P (true: T (mkA negb)).
End OK.

Module KO.
Set Primitive Projections.
Record A := mkA {
  T : Type;
  P : T -> bool;
}.

About P. (* No implicit arguments *)
Check P (true: T (mkA negb)).
(*
The command has indeed failed with message:
The term "true : T {| T := bool; P := negb |}" has type "T {| T := bool; P := negb |}"
while it is expected to have type "A".
*)


End KO.

¤ Dauer der Verarbeitung: 0.15 Sekunden  (vorverarbeitet)  ¤





Download des
Quellennavigators
Download des
sprechenden Kalenders

in der Quellcodebibliothek suchen




Haftungshinweis

Die Informationen auf dieser Webseite wurden nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit, noch Qualität der bereit gestellten Informationen zugesichert.


Bemerkung:

Die farbliche Syntaxdarstellung ist noch experimentell.


Bot Zugriff