Cherry pick 15071 from 4.02 (Fix #6510: Removal of shadowed constructors of extensible types can break the structure of definitions).

git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@15072 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02