Skip to content

Commit b19bce1

Browse files
committed
1 parent 646dda5 commit b19bce1

File tree

1 file changed

+10
-1
lines changed

1 file changed

+10
-1
lines changed

src/rocq_elpi_builtins.ml

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1676,6 +1676,15 @@ let univ_binder_compat_820 a b = a
16761676
let univ_binder_compat_820 a b = b
16771677
[%%endif]
16781678

1679+
[%%if coq = "8.20" || coq = "9.0" || coq= "9.1"]
1680+
let locality_of_options (o : options) = o.local <> Some false
1681+
[%%else]
1682+
let locality_of_options (o : options) = match o.local with
1683+
| Some true -> Libobject.Local
1684+
| Some false -> Libobject.SuperGlobal
1685+
| None -> Libobject.Export
1686+
[%%endif]
1687+
16791688
let coq_rest_builtins =
16801689
let open API.BuiltIn in
16811690
let open Pred in
@@ -3379,7 +3388,7 @@ Supported attributes:
33793388
} in
33803389
aux vars nenv env nargs term
33813390
in
3382-
let local = options.local <> Some false in
3391+
let local = locality_of_options options in
33833392
let onlyparsing = (onlyparsing = B.Given true) in
33843393
let name = Id.of_string name in
33853394
let vars, nenv, env, body = strip_n_lambas nargs env term in

0 commit comments

Comments
 (0)