From 9c5a447688365006c8e594edfb1e973db8d53454 Mon Sep 17 00:00:00 2001 From: Gaëtan Gilbert Date: Mon, 19 Mar 2018 14:13:01 +0100 Subject: Make parsing independent of the cumulativity flag. --- intf/vernacexpr.ml | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) (limited to 'intf') diff --git a/intf/vernacexpr.ml b/intf/vernacexpr.ml index df061bfb72..df746f7653 100644 --- a/intf/vernacexpr.ml +++ b/intf/vernacexpr.ml @@ -297,13 +297,9 @@ type inline = type module_ast_inl = module_ast * inline type module_binder = bool option * lident list * module_ast_inl -(** Cumulativity can be set globally, locally or unset locally and it - can not enabled at all. *) -type cumulative_inductive_parsing_flag = - | GlobalCumulativity - | GlobalNonCumulativity - | LocalCumulativity - | LocalNonCumulativity +(** [Some b] if locally enabled/disabled according to [b], [None] if + we should use the global flag. *) +type cumulative_inductive_parsing_flag = bool option (** {6 The type of vernacular expressions} *) -- cgit v1.2.3 From bca95952b541b209a3f8ca44d1ff119b976e54fb Mon Sep 17 00:00:00 2001 From: Gaëtan Gilbert Date: Thu, 22 Mar 2018 13:21:41 +0100 Subject: bool option -> (VernacCumulative | VernacNonCumulative) option --- intf/vernacexpr.ml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'intf') diff --git a/intf/vernacexpr.ml b/intf/vernacexpr.ml index df746f7653..c1c80b61d4 100644 --- a/intf/vernacexpr.ml +++ b/intf/vernacexpr.ml @@ -299,7 +299,7 @@ type module_binder = bool option * lident list * module_ast_inl (** [Some b] if locally enabled/disabled according to [b], [None] if we should use the global flag. *) -type cumulative_inductive_parsing_flag = bool option +type vernac_cumulative = VernacCumulative | VernacNonCumulative (** {6 The type of vernacular expressions} *) @@ -334,7 +334,7 @@ type nonrec vernac_expr = | VernacExactProof of constr_expr | VernacAssumption of (Decl_kinds.discharge * Decl_kinds.assumption_object_kind) * inline * (ident_decl list * constr_expr) with_coercion list - | VernacInductive of cumulative_inductive_parsing_flag * Decl_kinds.private_flag * inductive_flag * (inductive_expr * decl_notation list) list + | VernacInductive of vernac_cumulative option * Decl_kinds.private_flag * inductive_flag * (inductive_expr * decl_notation list) list | VernacFixpoint of Decl_kinds.discharge * (fixpoint_expr * decl_notation list) list | VernacCoFixpoint of Decl_kinds.discharge * (cofixpoint_expr * decl_notation list) list | VernacScheme of (lident option * scheme) list -- cgit v1.2.3