Over the course of a few patches[1], I've refactored exception handling in twoish ways:
1. Call sites which ASSERT that no exception occurred have been replaced with the ASSERT_NO_EXCEPTION macro[2]. 2. A new IGNORE_EXCEPTION macro is now available, intended to make it clear that a method's potential exception is being explicitly and intentionally ignored[3]. It should now be the case that any instantiation of an ExceptionCode in WebCore is followed by some usage of the variable other than simply passing it into a method. WebCore's current usage is a bit haphazard, however: we assert that no exception occurs at 168 call sites, and we ignore exceptions at 274 call sites. There's no real rhyme or reason to it... I believe that many of the sites currently ignoring exceptions should probably be asserting (or replaced with new, ExceptionCode-less APIs), but I didn't feel comfortable making that change. If you have some free time, it might be worthwhile to grep through code you're familiar with to see if making that change would be reasonable. Thanks! [1]: https://bugs.webkit.org/show_bug.cgi?id=108180 [2]: https://bugs.webkit.org/show_bug.cgi?id=109044 [3]: Most notably https://wkrev.com/142375 and http://wkrev.com/142271 -mike
_______________________________________________ webkit-dev mailing list webkit-dev@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-dev