summaryrefslogtreecommitdiff
path: root/parsing/depend.ml
diff options
context:
space:
mode:
authorGabriel Scherer <gabriel.scherer@gmail.com>2018-08-17 08:36:36 +0200
committerGabriel Scherer <gabriel.scherer@gmail.com>2018-08-20 19:57:47 +0200
commite348103ab8f234ca71cc7980d7ce656f2f26ef1b (patch)
treeb7db6390e25f534d55757c8eccae3ce6d1948754 /parsing/depend.ml
parent48b06a44aec78fc10496b18734570069b1ffff0b (diff)
downloadocaml-e348103ab8f234ca71cc7980d7ce656f2f26ef1b.tar.gz
parsetree.{row,object}_field: move attributes in the wrapper record
The concrete syntax only allows attributes on tags/constructors/fields (Rtag, Otag), not on inherited subtypes (Rinherit, Oinherit); we add this as new enforced invariant in ast_invariants.
Diffstat (limited to 'parsing/depend.ml')
-rw-r--r--parsing/depend.ml4
1 files changed, 2 insertions, 2 deletions
diff --git a/parsing/depend.ml b/parsing/depend.ml
index 4c0d720d18..031cb6b6b8 100644
--- a/parsing/depend.ml
+++ b/parsing/depend.ml
@@ -105,14 +105,14 @@ let rec add_type bv ty =
| Ptyp_object (fl, _) ->
List.iter
(fun {pof_desc; _} -> match pof_desc with
- | Otag (_, _, t) -> add_type bv t
+ | Otag (_, t) -> add_type bv t
| Oinherit t -> add_type bv t) fl
| Ptyp_class(c, tl) -> add bv c; List.iter (add_type bv) tl
| Ptyp_alias(t, _) -> add_type bv t
| Ptyp_variant(fl, _, _) ->
List.iter
(fun {prf_desc; _} -> match prf_desc with
- | Rtag(_,_,_,stl) -> List.iter (add_type bv) stl
+ | Rtag(_, _, stl) -> List.iter (add_type bv) stl
| Rinherit sty -> add_type bv sty)
fl
| Ptyp_poly(_, t) -> add_type bv t