Re: [whatwg/url] Record whether the URL parser removed newlines. (#284)

Our URL object is used for many things in the operating system that have nothing to do with HTML parsing.  We have many public APIs for apps that make URL objects behind the scenes, for example.  We also do many things with the network that have nothing to do with HTML.  We would not want to slow all those things down even by decreasing instruction locality by adding instructions in unlikely branches, and we would not want to require more memory for all those URL objects.  If I implemented this change in WebKit, I would have to look into how performance is actually affected and consider many things, but my initial thought is that I would just pre-scan the String given from the HTML/SVG parser to the URL parser.  As one of the probably majority of URL users that does things with URLs unrelated to HTML, I do not think this belongs in the URL specification.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/whatwg/url/pull/284#issuecomment-303833495

Received on Wednesday, 24 May 2017 19:55:23 UTC