notation.v 1.72 KB
Newer Older
Robbert Krebbers's avatar
Robbert Krebbers committed
1
From iris.proofmode Require Import coq_tactics environments.
Ralf Jung's avatar
Ralf Jung committed
2
From stdpp Require Export strings.
3
Set Default Proof Using "Type".
Robbert Krebbers's avatar
Robbert Krebbers committed
4
5

Delimit Scope proof_scope with env.
6
Arguments Envs _ _%proof_scope _%proof_scope _.
Robbert Krebbers's avatar
Robbert Krebbers committed
7
Arguments Enil {_}.
Robbert Krebbers's avatar
Robbert Krebbers committed
8
Arguments Esnoc {_} _%proof_scope _%string _%I.
Robbert Krebbers's avatar
Robbert Krebbers committed
9

Ralf Jung's avatar
Ralf Jung committed
10
Notation "" := Enil (only printing) : proof_scope.
11
Notation "Γ H : P" := (Esnoc Γ (INamed H) P)
Robbert Krebbers's avatar
Robbert Krebbers committed
12
  (at level 1, P at level 200,
13
   left associativity, format "Γ H  :  '[' P ']' '//'", only printing) : proof_scope.
14
15
Notation "Γ '_' : P" := (Esnoc Γ (IAnon _) P)
  (at level 1, P at level 200,
16
   left associativity, format "Γ '_'  :  '[' P ']' '//'", only printing) : proof_scope.
17

18
Notation "Γ '--------------------------------------' □ Δ '--------------------------------------' ∗ Q" :=
19
  (envs_entails (Envs Γ Δ _) Q%I)
Robbert Krebbers's avatar
Robbert Krebbers committed
20
  (at level 1, Q at level 200, left associativity,
Ralf Jung's avatar
Ralf Jung committed
21
  format "Γ '--------------------------------------' □ '//' Δ '--------------------------------------' ∗ '//' Q '//'", only printing) :
Robbert Krebbers's avatar
Robbert Krebbers committed
22
  stdpp_scope.
23
Notation "Δ '--------------------------------------' ∗ Q" :=
24
  (envs_entails (Envs Enil Δ _) Q%I)
Robbert Krebbers's avatar
Robbert Krebbers committed
25
  (at level 1, Q at level 200, left associativity,
Robbert Krebbers's avatar
Robbert Krebbers committed
26
  format "Δ '--------------------------------------' ∗ '//' Q '//'", only printing) : stdpp_scope.
Robbert Krebbers's avatar
Robbert Krebbers committed
27
Notation "Γ '--------------------------------------' □ Q" :=
28
  (envs_entails (Envs Γ Enil _) Q%I)
Robbert Krebbers's avatar
Robbert Krebbers committed
29
  (at level 1, Q at level 200, left associativity,
Robbert Krebbers's avatar
Robbert Krebbers committed
30
  format "Γ '--------------------------------------' □ '//' Q '//'", only printing)  : stdpp_scope.
31
Notation "'--------------------------------------' ∗ Q" := (envs_entails (Envs Enil Enil _) Q%I)
Robbert Krebbers's avatar
Robbert Krebbers committed
32
  (at level 1, Q at level 200, format "'--------------------------------------' ∗ '//' Q '//'", only printing) : stdpp_scope.