[Webkit-unassigned] [Bug 156972] [GTK] Crashes if DISPLAY is unset

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Mon Apr 25 10:26:08 PDT 2016


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

--- Comment #6 from Michael Catanzaro <mcatanzaro at igalia.com> ---
(In reply to comment #4) 
> Isn't the order ensured by the compiler? why do we have a warning when the
> order in the list doesn't match the one in the declaration, then?

Member variables are always initialized in the order they are declared in the class, NOT the order they are listed in the initializer list. Putting them out of order in the initializer list is thus very confusing, and worth warning about. We should never do that in WebKit.

Since relying on the order of declarations is risky -- someone could easily swap those in a "cleanup" and not notice the warning -- I agree with Berto that it's a good idea to do the assignment in the body of the constructor.

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.webkit.org/pipermail/webkit-unassigned/attachments/20160425/07a1020e/attachment.html>


More information about the webkit-unassigned mailing list