Ok, here is the PR: https://github.com/FreeCAD/FreeCAD/pull/2714.
However, I think a more general approach to avoid or at least detect generation of invalid IFC would be necessary. The issue we see here is not about modelling something in different ways according to the schema and then applications to support only one way or the other, which is indeed annoying. The issue here is, that syntactically invalid IFC is created which any schema-aware application would reject, no matter whether it can interpret the present concepts semantically or not. The current IFCOpenShell implementation does not seem to provide any support for checking of proper entity attribute types when creating entities. It just checks for simple data types.