Closed Bug 610951 Opened 15 years ago Closed 15 years ago

Failure to build in PluginInstanceChild.cpp with -std=gnu++0x

Categories

(Core Graveyard :: Plug-ins, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED
mozilla2.0b8

People

(Reporter: glandium, Assigned: glandium)

Details

Attachments

(1 file)

This is the error message I get when building with g++ -std=gnu++0x: ../../../dom/plugins/PluginInstanceChild.cpp:2644: error: narrowing conversion of 'rect.nsIntRect::y' from 'PRInt32' to 'uint16_t' inside { } ../../../dom/plugins/PluginInstanceChild.cpp:2644: error: narrowing conversion of 'rect.nsIntRect::x' from 'PRInt32' to 'uint16_t' inside { } ../../../dom/plugins/PluginInstanceChild.cpp:2644: error: narrowing conversion of 'rect.nsIntRect::YMost()' from 'PRInt32' to 'uint16_t' inside { } ../../../dom/plugins/PluginInstanceChild.cpp:2644: error: narrowing conversion of 'rect.nsIntRect::XMost()' from 'PRInt32' to 'uint16_t' inside { } Casting to uint16_t is enough to make this build and on par with what other compilers non complaining would do, but it could be worth checking if there can't be any overflows there. (though I'd expect these values to be on-screen positions and lengths, which means a uint16_t is probably good enough)
Attachment #489435 - Flags: review?(jst)
Attachment #489435 - Flags: review?(jst)
Attachment #489435 - Flags: review+
Attachment #489435 - Flags: approval2.0+
Assignee: nobody → mh+mozilla
Status: NEW → RESOLVED
Closed: 15 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla2.0b8
Product: Core → Core Graveyard
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: