Closed Bug 1056264 Opened 10 years ago Closed 10 years ago

Mark helper-typedef as permissibly unused, in webrtc's compile_assert.h COMPILE_ASSERT macro

Categories

(Core :: WebRTC, defect)

x86_64
Linux
defect
Not set
normal

Tracking

()

RESOLVED DUPLICATE of bug 1020661

People

(Reporter: dholbert, Unassigned)

Details

When building mozilla-central with GCC 4.8, I get build warnings like... { 8:25.82 pkixocsp_VerifyEncodedOCSPResponse.o 8:26.22 In file included from $SRCDIR/media/webrtc/signaling/../trunk/webrtc/system_wrappers/interface/scoped_ptr.h:107:0, 8:26.22 from $SRCDIR/media/webrtc/signaling/../trunk/webrtc/system_wrappers/interface/aligned_malloc.h:22, 8:26.22 from $SRCDIR/media/webrtc/signaling/../trunk/webrtc/common_video/plane.h:14, 8:26.22 from $SRCDIR/media/webrtc/signaling/../trunk/webrtc/common_video/interface/i420_video_frame.h:18, 8:26.22 from $SRCDIR/media/webrtc/signaling/../trunk/webrtc/modules/video_coding/codecs/interface/video_codec_interface.h:17, 8:26.23 from $SRCDIR/media/webrtc/signaling/./src/media-conduit/VideoConduit.h:24, 8:26.23 from $SRCDIR/media/webrtc/signaling/src/peerconnection/PeerConnectionMedia.cpp:16: 8:26.23 $SRCDIR/media/webrtc/signaling/../trunk/webrtc/system_wrappers/interface/scoped_ptr.h: In constructor ‘webrtc::DefaultDeleter<T>::DefaultDeleter(const webrtc::DefaultDeleter<U>&)’: 8:26.23 Warning: -Wunused-local-typedefs in $SRCDIR/media/webrtc/trunk/webrtc/system_wrappers/interface/scoped_ptr.h: typedef ‘U_ptr_must_implicitly_convert_to_T_ptr’ locally defined but not used 8:26.23 $SRCDIR/media/webrtc/signaling/../trunk/webrtc/system_wrappers/interface/scoped_ptr.h:137:20: warning: typedef ‘U_ptr_must_implicitly_convert_to_T_ptr’ locally defined but not used [-Wunused-local-typedefs] 8:26.23 U_ptr_must_implicitly_convert_to_T_ptr); 8:26.23 ^ 8:26.23 $SRCDIR/media/webrtc/signaling/../trunk/webrtc/system_wrappers/interface/compile_assert.h:39:39: note: in definition of macro ‘COMPILE_ASSERT’ 8:26.23 typedef CompileAssert<(bool(expr))> msg[bool(expr) ? 1 : -1] } ...because compile_assert.h creates a typedef as a way of doing static assertions, and GCC 4.8 warns about unused typedefs. This is the same as bug 890539, except that bug was about skia's copy of compile_assert.h, and this on is about WebRTC's copy. We should just do the same thing we did there -- mark this typedef as permissably-unused. (Really, WebRTC should be using static_assert instead of this COMPILE_ASSERT macro, but that's a more substantial change and requires more assumptions about which compiler-versions are supported.)
Summary: Mark webrtc's → Mark helper-typedef as permissibly unused, in webrtc's compile_assert.h COMPILE_ASSERT macro
Actually, this is mostly the same issue as bug 1020661. (Plus, there are some other unused typedefs in scoped_ptr.h, so just fixing compile_assert.h isn't sufficient.) Duping to bug 1020661.
Status: NEW → RESOLVED
Closed: 10 years ago
Resolution: --- → DUPLICATE
You need to log in before you can comment on or make changes to this bug.