fix various problems in gfx/ turned up by compiling with clang-cl

RESOLVED FIXED in Firefox 45

Status

()

defect
RESOLVED FIXED
4 years ago
4 years ago

People

(Reporter: froydnj, Assigned: froydnj)

Tracking

unspecified
mozilla45
Points:
---

Firefox Tracking Flags

(firefox45 fixed)

Details

Attachments

(10 attachments)

1.84 KB, patch
bas.schouten
: review+
Details | Diff | Splinter Review
1.09 KB, patch
bas.schouten
: review+
Details | Diff | Splinter Review
1.05 KB, patch
bas.schouten
: review+
Details | Diff | Splinter Review
1.38 KB, patch
bas.schouten
: review+
Details | Diff | Splinter Review
1.20 KB, patch
bas.schouten
: review+
Details | Diff | Splinter Review
1.13 KB, patch
bas.schouten
: review+
Details | Diff | Splinter Review
1.81 KB, patch
bas.schouten
: review+
Details | Diff | Splinter Review
1.10 KB, patch
bas.schouten
: review+
Details | Diff | Splinter Review
1.16 KB, patch
bas.schouten
: review+
Details | Diff | Splinter Review
1.11 KB, patch
bas.schouten
: review+
Details | Diff | Splinter Review
All of these are simple warnings with (seemingly) obvious fixes.  They're split
up very fine-grained, ideally to make them easier to review.
Member fields are supposed to be initialized in the order they are
declared, but the constructors of DataTextureSourceD3D9 initialized
mFormat prior to mCompositor.  This is probably harmless, but it does
cause a warning on clang-cl, so let's fix it.
Attachment #8684384 - Flags: review?(bas)
Member fields are supposed to be initialized in the order they are
declared, but the constructor of SourceSurfaceD2D1 initialized
mDrawTarget prior to mDevice.  This is probably harmless, but it does
cause a warning on clang-cl, so let's fix it.
Attachment #8684385 - Flags: review?(bas)
None of the other DrawPrimitive calls in DrawQuad are checked, so
discaring the result from this call of DrawPrimitive seems OK.
Attachment #8684391 - Flags: review?(bas)
Attachment #8684384 - Flags: review?(bas) → review+
Attachment #8684385 - Flags: review?(bas) → review+
Attachment #8684386 - Flags: review?(bas) → review+
Attachment #8684388 - Flags: review?(bas) → review+
Comment on attachment 8684389 [details] [diff] [review]
remove unused variable in gfxDWriteFonts.cpp

Review of attachment 8684389 [details] [diff] [review]:
-----------------------------------------------------------------

If we're going to care about unused variable warnings, let's just enable them as errors on MSVC builds as well once we've removed them.
Attachment #8684389 - Flags: review?(bas) → review+
Attachment #8684390 - Flags: review?(bas) → review+
Attachment #8684391 - Flags: review?(bas) → review+
Attachment #8684392 - Flags: review?(bas) → review+
Attachment #8684393 - Flags: review?(bas) → review+
Attachment #8684394 - Flags: review?(bas) → review+
You need to log in before you can comment on or make changes to this bug.