I am developing an extension for serializing data to Protocol Buffers. In particular, it accepts attributes on variant constructors that define their mapping to integer keys used in the protocol, like this: `type v = A [@key 1] | B [@key 10] of int`.

It would make sense if I could define the exact same type, mapping to exact same message, with polymorphic variants: `type v' = `A [@key 1] | `B [@key 10] of int'. However, this is currently not possible, as parser does not accept attributes in that position.