I think this one is problematic too:
> Using the union keyword produces an error. … It was replaced by std::variant, which is safer.
Union is horribly unsafe, but at least union identifies its fields by name. Variant identifies its fields by position (unergonomic, error prone, and horrible for refactoring) or by type (unpleasant or useless when the type has no name or an unstable name, and even worse when two choices have the same type).
C++ needs an actual sum type, and variant isn’t it. Sorry.