Skip to content
Snippets Groups Projects
Commit a07cc19d authored by Robbert Krebbers's avatar Robbert Krebbers
Browse files

New syntax for types in frontend.

This allows for constant expressions in array sizes and makes way for
future extensions.
parent b9117014
No related branches found
No related tags found
No related merge requests found
...@@ -22,7 +22,6 @@ Proof. congruence. Qed. ...@@ -22,7 +22,6 @@ Proof. congruence. Qed.
(** The non dependent elimination principle on the option type. *) (** The non dependent elimination principle on the option type. *)
Definition default {A B} (b : B) (x : option A) (f : A B) : B := Definition default {A B} (b : B) (x : option A) (f : A B) : B :=
match x with None => b | Some a => f a end. match x with None => b | Some a => f a end.
Hint Extern 1000 => simpl (default _ (Some _) _) || simpl (default _ None _).
(** The [from_option] function allows us to get the value out of the option (** The [from_option] function allows us to get the value out of the option
type by specifying a default value. *) type by specifying a default value. *)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment