Bug 198044 - Replace Util::run with runUntil that takes a bool reference instead of a pointer
Summary: Replace Util::run with runUntil that takes a bool reference instead of a pointer
Status: RESOLVED WONTFIX
Alias: None
Product: WebKit
Classification: Unclassified
Component: Tools / Tests (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Alex Christensen
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2019-05-20 10:14 PDT by Alex Christensen
Modified: 2019-07-18 16:33 PDT (History)
3 users (show)

See Also:


Attachments
Patch (643.25 KB, patch)
2019-05-20 10:29 PDT, Alex Christensen
no flags Details | Formatted Diff | Diff
Patch (647.10 KB, patch)
2019-05-20 10:33 PDT, Alex Christensen
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Alex Christensen 2019-05-20 10:14:21 PDT
Replace Util::run with Util::runUntil that takes a bool reference instead of a pointer
Comment 1 Alex Christensen 2019-05-20 10:29:21 PDT
Created attachment 370260 [details]
Patch
Comment 2 Alex Christensen 2019-05-20 10:33:43 PDT
Created attachment 370261 [details]
Patch
Comment 3 Sam Weinig 2019-05-20 11:02:44 PDT
Comment on attachment 370261 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=370261&action=review

> Tools/TestWebKitAPI/Utilities.h:33
> -void run(bool* done);
> +void runUntil(const bool& done);

I made this (or at least I think it was me) a pointer rather than a reference because I thought it looked better at call sites to use the &. I still kind of feel that way, but not too strongly.
Comment 4 Alex Christensen 2019-05-20 11:33:13 PDT
(In reply to Sam Weinig from comment #3)
> Comment on attachment 370261 [details]
> Patch
> 
> View in context:
> https://bugs.webkit.org/attachment.cgi?id=370261&action=review
> 
> > Tools/TestWebKitAPI/Utilities.h:33
> > -void run(bool* done);
> > +void runUntil(const bool& done);
> 
> I made this (or at least I think it was me) a pointer rather than a
> reference because I thought it looked better at call sites to use the &. I
> still kind of feel that way, but not too strongly.

I think the new name makes it clear what is going on, and I think this is a significant improvement.
Comment 5 Alex Christensen 2019-07-18 16:32:39 PDT
This has bit rotted, and apparently wasn't popular.