Details
Description
https://stackoverflow.com/a/43619742
Some users of the class might do something like QUrl("example.com") and expect it to fill the host but it actually fills the path due to how URL standard is defined (if there is no scheme, path takes priority to support URLs like [john@example.com|mailto:john@example.com] where the email address is a path and the host is empty).
While there is no bug in Qt implementation, I think it would be a worthwhile addition to the class documentation to warn users about this potential trap. Maybe add static factory functions, similar to what QString has for different encodings (here: for different elements of the URL).