Multiple inheritance allows to create [string, nil] attributes, bug?
alvassin opened this issue · comments
From documentation: Also, it is not allowed to inherit from different kind of primitive types, for example [ number, string ]
I understand why it is possible to inherit [any, string]
or [number, integer]
(it is used same branch of derived raml types).
But what about [number, nil]
? From my point of view it should be not allowed. Is that a but of raml-js-parser?
number | nil
is a valid union type. but not [number, nil]
derived type.