AdditionalProperties and oneOf in one Schema
Demonstrates and fixes a problem when a schema has both additionalProperties and oneOf union, and two clashing MarshalJSON and UnmarshalJSON methods are generated:
https://github.com/deepmap/oapi-codegen/issues/763
The handling isn't perfect, because the fields that belong to the variants also get copied into the additionalProperties on unmarshal (since in the general case with delayed unmarshalling we don't yet know which of the variants we are dealing with) but it's strictly better than the previous behaviour when invalid code was generated, while it doesn't change the behaviour in all other cases.
An alternative treatment could be that in such cases the additional properties are "propagated down" into the oneOf elements