Details
-
Task
-
Resolution: Unresolved
-
P2: Important
-
None
-
None
Description
What we actually want here is an abstraction over "two URLs and two strings and weird behavior". That should be a type that, in the common case where all the URLs are the same, should be less than 8 pointers large (2x QUrl + 2x QString). When we actually have redirection and/or interception it should allocate extra space for that, and it should warn when we have both.
In particular, URL redirection changes the original URL so that further URL resolution is based on the new, redirected one. URL interception, however, changes only the "physical" URL we use to fetch the content. The original URL used for further resolution stays the same. If we do both, chaos ensues.
We should also check whether the technique of keeping a QString as cache for QUrl::toString() is actually still worthwhile and if so, whether we can optimize QUrl to be better at toString() rather than wasting the space for extra QStrings there.