Closed Bug 1169712 Opened 9 years ago Closed 9 years ago

js fails to build on Fedora 22 / gcc 5.1

Categories

(Core :: JavaScript Engine, defect)

Other Branch
defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla41
Tracking Status
firefox41 --- fixed

People

(Reporter: tromey, Assigned: tromey)

Details

Attachments

(1 file)

I upgraded to Fedora 22, which uses GCC 5.1.1 as its system compiler.
GCC now says:

In file included from /home/tromey/firefox-git/tree-2/obj-x86_64-unknown-linux-gnu/js/src/jsapi-tests/Unified_cpp_js_src_jsapi-tests2.cpp:2:0:
/home/tromey/firefox-git/tree-2/js/src/jsapi-tests/testGCMarking.cpp: In member function ‘void CCWTestTracer::callback(void**, JS::TraceKind)’:
/home/tromey/firefox-git/tree-2/js/src/jsapi-tests/testGCMarking.cpp:21:43: error: format ‘%d’ expects argument of type ‘int’, but argument 2 has type ‘JS::TraceKind’ [-Werror=format=]
         printf("kind         = %d\n", kind);
                                           ^
/home/tromey/firefox-git/tree-2/js/src/jsapi-tests/testGCMarking.cpp:22:51: error: format ‘%d’ expects argument of type ‘int’, but argument 2 has type ‘JS::TraceKind’ [-Werror=format=]
         printf("expectedKind = %d\n", expectedKind);
                                                   ^


It looks like -Wformat has gotten a bit more pedantic.

Patch to follow.
Attachment #8612998 - Flags: review?(nfitzgerald)
Comment on attachment 8612998 [details] [diff] [review]
add casts for GCC 5.1 -Wformat

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

Thanks!
Attachment #8612998 - Flags: review?(nfitzgerald) → review+
Keywords: checkin-needed
https://hg.mozilla.org/mozilla-central/rev/a281ea0a58e6
Status: ASSIGNED → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla41
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: