Last Comment Bug 772738 - Avoid "unused variable 'tmp'" warnings for empty CC traverse method implementations
: Avoid "unused variable 'tmp'" warnings for empty CC traverse method implement...
Product: Core
Classification: Components
Component: XPCOM (show other bugs)
: unspecified
: x86 Mac OS X
-- normal (vote)
: mozilla16
Assigned To: :Ehsan Akhgari
: Nathan Froyd [:froydnj][high latency until 6 March]
Depends on:
  Show dependency treegraph
Reported: 2012-07-10 21:22 PDT by :Ehsan Akhgari
Modified: 2012-07-12 09:40 PDT (History)
3 users (show)
See Also:
Crash Signature:
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---

Patch (v1) (817 bytes, patch)
2012-07-10 21:27 PDT, :Ehsan Akhgari
bugs: review+
Details | Diff | Splinter Review

Description User image :Ehsan Akhgari 2012-07-10 21:22:31 PDT
moz/mozilla-central/dom/indexedDB/IDBWrapperCache.cpp:14:1: warning: unused variable 'tmp' [-Wunused-variable]
../../dist/include/nsCycleCollectionParticipant.h:517:3: note: expanded from macro 'NS_IMPL_CYCLE_COLLECTION_TRAVERSE_BEGIN_INHERITED'
../../dist/include/nsCycleCollectionParticipant.h:504:13: note: expanded from macro 'NS_IMPL_CYCLE_COLLECTION_TRAVERSE_BEGIN_INTERNAL'
    _class *tmp = static_cast<_class*>(Downcast(s));
1 warning generated.

The UNLINK_END macro has this protection in place.  We should add it for TRAVERSE too.
Comment 1 User image :Ehsan Akhgari 2012-07-10 21:27:18 PDT
Created attachment 640909 [details] [diff] [review]
Patch (v1)
Comment 3 User image Andrew McCreight [:mccr8] 2012-07-11 06:41:14 PDT
Weird, I thought I'd gone through and fixed all of these.  Thanks for fixing it!
Comment 4 User image Ed Morley [:emorley] 2012-07-12 09:40:19 PDT

Note You need to log in before you can comment on or make changes to this bug.