AXObjectCache::postNotification should use an enum instead of a bool (since it's a multi-argument function) I'm slowly trying to rid WebKit of this pattern, as it leads to very difficult to understand callsites: axObjectCache()->postNotification(node(), AXObjectCache::AXValueChanged, true); At least: axObjectCache()->postNotification(node(), AXObjectCache::AXValueChanged, PostToElement); would be clearer. Although it's not yet clear to me what the "postToElement" bool is supposed to do. :) Once I figure out what postToElement means, I can come up with nice names for a replacement enum. Any suggestions would be most welcome. :)
(In reply to comment #0) > AXObjectCache::postNotification should use an enum instead of a bool (since it's a multi-argument function) > > I'm slowly trying to rid WebKit of this pattern, as it leads to very difficult to understand callsites: > axObjectCache()->postNotification(node(), AXObjectCache::AXValueChanged, true); > > At least: > axObjectCache()->postNotification(node(), AXObjectCache::AXValueChanged, PostToElement); > > would be clearer. Although it's not yet clear to me what the "postToElement" bool is supposed to do. :) > > Once I figure out what postToElement means, I can come up with nice names for a replacement enum. Any suggestions would be most welcome. :) I was given this same feedback (we should not use a bool) in response to another patch that I landed. I fixed this issue under: https://bugs.webkit.org/show_bug.cgi?id=121504 before I saw this bug. Apologies. Marking as dupe, but note that this bug was filed first. Not sure if there's a better way to indicate that. Thanks! *** This bug has been marked as a duplicate of bug 121504 ***