Closed Bug 1405439 Opened 8 years ago Closed 8 years ago

Cannot cast nullptr to boolean in VR

Categories

(Core :: DOM: Core & HTML, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla58
Tracking Status
firefox58 --- fixed

People

(Reporter: tjr, Assigned: tjr)

References

(Blocks 1 open bug)

Details

(Whiteboard: [tor])

Attachments

(1 file)

I do not believe it is legal to cast nullptr to boolean, I know for certain it causes an error for MinGW: > /builds/worker/workspace/build/src/gfx/vr/gfxVROculus.cpp:1113:12: error: converting to 'bool' from 'std::nullptr_t' requires direct-initialization [-fpermissive]
Comment on attachment 8914868 [details] Bug 1405439 Do not cast nullptr to bool implicitly, instead return false in gfx/vr https://reviewboard.mozilla.org/r/186130/#review191170 Good catch, thanks! Indeed, these should be "false" not "nullptr"
Attachment #8914868 - Flags: review?(kgilbert) → review+
Keywords: checkin-needed
Pushed by ryanvm@gmail.com: https://hg.mozilla.org/integration/autoland/rev/5e71f573019a Do not cast nullptr to bool implicitly, instead return false in gfx/vr r=kip
Keywords: checkin-needed
Status: NEW → RESOLVED
Closed: 8 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla58
Component: DOM → DOM: Core & HTML
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: