[Webkit-unassigned] [Bug 30342] Eliminate the use of String::format

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Sun Feb 3 18:27:24 PST 2019


https://bugs.webkit.org/show_bug.cgi?id=30342

--- Comment #10 from Michael Catanzaro <mcatanzaro at igalia.com> ---
(In reply to Darin Adler from comment #9)
> The scope of this bug is too narrow. I think what we really want to do is to
> eliminate WebKit project use of C library formatting functions in the printf
> family. Eliminating String::format is a necessary part of this, but not
> sufficient to cover the whole task. At some point we might want a bug about
> that.

E.g. our logging functions make heavy use of format specifiers. On Unix they boil down to fprintf(stderr, ...) but it takes some investigation every time I need to discover that.

I push a lot of commits changing "%llu" to "%" PRIu64. uint64_t is long long unsigned int on Mac but just long unsigned int on Linux, so using %llu is an error. That's just one example of an annoying difference. Another: Mac has format specifiers that fprintf doesn't accept, e.g. %{private} or something like that. Logging will be a lot more annoying to do without formats, but safer indeed....

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20190204/42545f1c/attachment.html>


More information about the webkit-unassigned mailing list