Skip to content

Commit

Permalink
Bug 1207030 - Enable -Wshadow flag in more directories that have no -…
Browse files Browse the repository at this point in the history
…Wshadow warnings. r=glandium
  • Loading branch information
cpeterso committed Sep 23, 2015
1 parent 7e92476 commit e56b759
Show file tree
Hide file tree
Showing 179 changed files with 514 additions and 359 deletions.
3 changes: 3 additions & 0 deletions accessible/windows/uia/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -18,3 +18,6 @@ LOCAL_INCLUDES += [
]

FINAL_LIBRARY = 'xul'

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
3 changes: 3 additions & 0 deletions browser/components/about/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -17,3 +17,6 @@ FINAL_LIBRARY = 'browsercomps'
LOCAL_INCLUDES += [
'../build',
]

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
3 changes: 3 additions & 0 deletions browser/components/build/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -38,3 +38,6 @@ if CONFIG['OS_ARCH'] == 'WINNT':
# GTK2: Need to link with glib for GNOME shell service
if CONFIG['MOZ_WIDGET_TOOLKIT'] in ('cocoa', 'gtk2', 'gtk3'):
OS_LIBS += CONFIG['TK_LIBS']

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
3 changes: 3 additions & 0 deletions browser/components/dirprovider/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -21,3 +21,6 @@ FINAL_LIBRARY = 'browsercomps'
LOCAL_INCLUDES += [
'../build'
]

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
3 changes: 3 additions & 0 deletions browser/components/feeds/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -42,3 +42,6 @@ LOCAL_INCLUDES += [

with Files('**'):
BUG_COMPONENT = ('Firefox', 'RSS Discovery and Preview')

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
3 changes: 3 additions & 0 deletions browser/components/shell/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -52,3 +52,6 @@ CXXFLAGS += CONFIG['TK_CFLAGS']

with Files('**'):
BUG_COMPONENT = ('Firefox', 'Shell Integration')

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
3 changes: 3 additions & 0 deletions devtools/server/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -35,3 +35,6 @@ DevToolsModules(
'protocol.js',
'worker.js'
)

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
3 changes: 3 additions & 0 deletions docshell/base/timeline/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -35,3 +35,6 @@ FINAL_LIBRARY = 'xul'
LOCAL_INCLUDES += [
'/docshell/base'
]

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
3 changes: 3 additions & 0 deletions docshell/shistory/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -32,3 +32,6 @@ LOCAL_INCLUDES += [
]

FINAL_LIBRARY = 'xul'

if CONFIG['CLANG_CXX']:
CXXFLAGS += ['-Wshadow']
3 changes: 3 additions & 0 deletions dom/activities/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -38,3 +38,6 @@ LOCAL_INCLUDES += [
include('/ipc/chromium/chromium-config.mozbuild')

FINAL_LIBRARY = 'xul'

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
3 changes: 3 additions & 0 deletions dom/base/test/gtest/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -15,3 +15,6 @@ LOCAL_INCLUDES += [
include('/ipc/chromium/chromium-config.mozbuild')

FINAL_LIBRARY = 'xul-gtest'

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
3 changes: 3 additions & 0 deletions dom/battery/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -18,3 +18,6 @@ include('/ipc/chromium/chromium-config.mozbuild')
FINAL_LIBRARY = 'xul'

MOCHITEST_MANIFESTS += ['test/mochitest.ini']

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
3 changes: 3 additions & 0 deletions dom/broadcastchannel/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -29,3 +29,6 @@ MOCHITEST_CHROME_MANIFESTS += ['tests/chrome.ini']
include('/ipc/chromium/chromium-config.mozbuild')

FINAL_LIBRARY = 'xul'

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
3 changes: 3 additions & 0 deletions dom/browser-element/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -52,3 +52,6 @@ MOCHITEST_MANIFESTS += [
'mochitest/mochitest.ini',
'mochitest/priority/mochitest.ini',
]

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
3 changes: 3 additions & 0 deletions dom/cellbroadcast/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -36,3 +36,6 @@ IPDL_SOURCES += [
include('/ipc/chromium/chromium-config.mozbuild')

FINAL_LIBRARY = 'xul'

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
3 changes: 3 additions & 0 deletions dom/devicestorage/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -45,3 +45,6 @@ MOCHITEST_MANIFESTS += [
'test/mochitest.ini',
]
MOCHITEST_CHROME_MANIFESTS += ['test/chrome.ini']

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
3 changes: 3 additions & 0 deletions dom/encoding/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -45,3 +45,6 @@ MOCHITEST_MANIFESTS += [
]
MOCHITEST_CHROME_MANIFESTS += ['test/chrome.ini']
XPCSHELL_TESTS_MANIFESTS += ['test/unit/xpcshell.ini']

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
3 changes: 3 additions & 0 deletions dom/filesystem/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -41,3 +41,6 @@ include('/ipc/chromium/chromium-config.mozbuild')
LOCAL_INCLUDES += [
'/dom/base',
]

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
2 changes: 2 additions & 0 deletions dom/fmradio/ipc/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -30,3 +30,5 @@ LOCAL_INCLUDES += [
'/dom/fmradio',
]

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
3 changes: 3 additions & 0 deletions dom/fmradio/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -32,3 +32,6 @@ LOCAL_INCLUDES += [
'../system/gonk',
]
include('/ipc/chromium/chromium-config.mozbuild')

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
3 changes: 3 additions & 0 deletions dom/gamepad/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -54,3 +54,6 @@ CFLAGS += CONFIG['GLIB_CFLAGS']
CFLAGS += CONFIG['MOZ_DBUS_GLIB_CFLAGS']
CXXFLAGS += CONFIG['GLIB_CFLAGS']
CXXFLAGS += CONFIG['MOZ_DBUS_GLIB_CFLAGS']

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
3 changes: 3 additions & 0 deletions dom/geolocation/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -51,3 +51,6 @@ elif CONFIG['MOZ_WIDGET_TOOLKIT'] == 'windows':
LOCAL_INCLUDES += [
'/dom/system/windows',
]

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
3 changes: 3 additions & 0 deletions dom/icc/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -55,3 +55,6 @@ FINAL_LIBRARY = 'xul'
LOCAL_INCLUDES += [
'/dom/system/gonk',
]

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
3 changes: 3 additions & 0 deletions dom/inputport/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -44,3 +44,6 @@ XPCSHELL_TESTS_MANIFESTS += ['test/xpcshell/xpcshell.ini']
include('/ipc/chromium/chromium-config.mozbuild')

FINAL_LIBRARY = 'xul'

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
3 changes: 3 additions & 0 deletions dom/json/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -20,3 +20,6 @@ FINAL_LIBRARY = 'xul'

XPCSHELL_TESTS_MANIFESTS += ['test/unit/xpcshell.ini']
MOCHITEST_MANIFESTS += ['test/mochitest.ini']

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
3 changes: 3 additions & 0 deletions dom/jsurl/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -22,3 +22,6 @@ FINAL_LIBRARY = 'xul'
include('/ipc/chromium/chromium-config.mozbuild')

MOCHITEST_MANIFESTS += ['test/mochitest.ini']

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
2 changes: 2 additions & 0 deletions dom/mathml/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -16,3 +16,5 @@ LOCAL_INCLUDES += [
'/dom/base',
]

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
3 changes: 3 additions & 0 deletions dom/media/android/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -25,3 +25,6 @@ LOCAL_INCLUDES += [
]

FINAL_LIBRARY = 'xul'

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
3 changes: 3 additions & 0 deletions dom/media/gmp-plugin-openh264/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -22,3 +22,6 @@ USE_STATIC_LIBS = True
NO_VISIBILITY_FLAGS = True
# Don't use STL wrappers; this isn't Gecko code
DISABLE_STL_WRAPPING = True

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
3 changes: 3 additions & 0 deletions dom/media/gmp-plugin/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -24,3 +24,6 @@ USE_STATIC_LIBS = True
NO_VISIBILITY_FLAGS = True
# Don't use STL wrappers; this isn't Gecko code
DISABLE_STL_WRAPPING = True

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
3 changes: 3 additions & 0 deletions dom/media/imagecapture/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -14,3 +14,6 @@ UNIFIED_SOURCES += [
]

FINAL_LIBRARY = 'xul'

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
3 changes: 3 additions & 0 deletions dom/messagechannel/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -37,3 +37,6 @@ LOCAL_INCLUDES += [
include('/ipc/chromium/chromium-config.mozbuild')

FINAL_LIBRARY = 'xul'

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
3 changes: 3 additions & 0 deletions dom/nfc/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -51,3 +51,6 @@ if CONFIG['MOZ_WIDGET_TOOLKIT'] == 'gonk' and CONFIG['MOZ_NFC']:
include('/ipc/chromium/chromium-config.mozbuild')

FINAL_LIBRARY = 'xul'

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
3 changes: 3 additions & 0 deletions dom/offline/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -16,3 +16,6 @@ LOCAL_INCLUDES += [
]

FINAL_LIBRARY = 'xul'

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
3 changes: 3 additions & 0 deletions dom/payment/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -37,3 +37,6 @@ LOCAL_INCLUDES += [
XPCSHELL_TESTS_MANIFESTS += ['tests/unit/xpcshell.ini']

MOCHITEST_MANIFESTS += ['tests/mochitest/mochitest.ini']

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
3 changes: 3 additions & 0 deletions dom/permission/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -47,3 +47,6 @@ if CONFIG['MOZ_TIME_MANAGER']:
MOCHITEST_MANIFESTS += ['tests/mochitest-time.ini']

FINAL_LIBRARY = 'xul'

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
3 changes: 3 additions & 0 deletions dom/plugins/base/android/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -36,3 +36,6 @@ LOCAL_INCLUDES += [
DEFINES['MOZ_APP_NAME'] = '"%s"' % CONFIG['MOZ_APP_NAME']

CXXFLAGS += CONFIG['MOZ_CAIRO_CFLAGS']

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
3 changes: 3 additions & 0 deletions dom/power/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -33,3 +33,6 @@ FINAL_LIBRARY = 'xul'

MOCHITEST_MANIFESTS += ['test/mochitest.ini']
BROWSER_CHROME_MANIFESTS += ['test/browser.ini']

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
3 changes: 3 additions & 0 deletions dom/presentation/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -57,3 +57,6 @@ IPDL_SOURCES += [
include('/ipc/chromium/chromium-config.mozbuild')

FINAL_LIBRARY = 'xul'

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
3 changes: 3 additions & 0 deletions dom/presentation/provider/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -16,3 +16,6 @@ UNIFIED_SOURCES += [

include('/ipc/chromium/chromium-config.mozbuild')
FINAL_LIBRARY = 'xul'

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
3 changes: 3 additions & 0 deletions dom/requestsync/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -29,3 +29,6 @@ SOURCES += [
include('/ipc/chromium/chromium-config.mozbuild')

FINAL_LIBRARY = 'xul'

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
3 changes: 3 additions & 0 deletions dom/smil/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -70,3 +70,6 @@ LOCAL_INCLUDES += [
]

FINAL_LIBRARY = 'xul'

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
3 changes: 3 additions & 0 deletions dom/speakermanager/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -21,3 +21,6 @@ UNIFIED_SOURCES += [
include('/ipc/chromium/chromium-config.mozbuild')

FINAL_LIBRARY = 'xul'

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
3 changes: 3 additions & 0 deletions dom/storage/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -31,3 +31,6 @@ LOCAL_INCLUDES += [

if CONFIG['ENABLE_TESTS']:
DEFINES['DOM_STORAGE_TESTS'] = True

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
2 changes: 2 additions & 0 deletions dom/system/android/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -16,3 +16,5 @@ LOCAL_INCLUDES += [
'/dom/geolocation',
]

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
3 changes: 3 additions & 0 deletions dom/system/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -63,3 +63,6 @@ DEFINES['DLL_SUFFIX'] = '"%s"' % CONFIG['DLL_SUFFIX']

MOCHITEST_CHROME_MANIFESTS += ['tests/chrome.ini']
MOCHITEST_MANIFESTS += ['tests/mochitest.ini']

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
3 changes: 3 additions & 0 deletions dom/system/qt/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -24,3 +24,6 @@ if CONFIG['MOZ_ENABLE_QT5FEEDBACK']:
include('/ipc/chromium/chromium-config.mozbuild')

FINAL_LIBRARY = 'xul'

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
3 changes: 3 additions & 0 deletions dom/system/windows/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -14,3 +14,6 @@ LOCAL_INCLUDES += [
]

FINAL_LIBRARY = 'xul'

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
3 changes: 3 additions & 0 deletions dom/telephony/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -79,3 +79,6 @@ if CONFIG['MOZ_WIDGET_TOOLKIT'] == 'gonk' and CONFIG['MOZ_B2G_RIL']:
include('/ipc/chromium/chromium-config.mozbuild')

FINAL_LIBRARY = 'xul'

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
3 changes: 3 additions & 0 deletions dom/time/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -27,3 +27,6 @@ UNIFIED_SOURCES += [
include('/ipc/chromium/chromium-config.mozbuild')

FINAL_LIBRARY = 'xul'

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
3 changes: 3 additions & 0 deletions dom/tv/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -45,3 +45,6 @@ XPCSHELL_TESTS_MANIFESTS += ['test/xpcshell/xpcshell.ini']
include('/ipc/chromium/chromium-config.mozbuild')

FINAL_LIBRARY = 'xul'

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
3 changes: 3 additions & 0 deletions dom/voicemail/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -51,3 +51,6 @@ LOCAL_INCLUDES += [
include('/ipc/chromium/chromium-config.mozbuild')

FINAL_LIBRARY = 'xul'

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
3 changes: 3 additions & 0 deletions dom/vr/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -18,3 +18,6 @@ FINAL_LIBRARY = 'xul'
LOCAL_INCLUDES += [
'/dom/base'
]

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
3 changes: 3 additions & 0 deletions dom/workers/test/gtest/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -11,3 +11,6 @@ UNIFIED_SOURCES = [
include('/ipc/chromium/chromium-config.mozbuild')

FINAL_LIBRARY = 'xul-gtest'

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
3 changes: 3 additions & 0 deletions editor/txmgr/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -28,3 +28,6 @@ UNIFIED_SOURCES += [
]

FINAL_LIBRARY = 'xul'

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
3 changes: 3 additions & 0 deletions editor/txtsvc/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -24,3 +24,6 @@ UNIFIED_SOURCES += [
]

FINAL_LIBRARY = 'xul'

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
2 changes: 2 additions & 0 deletions embedding/browser/build/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,5 @@ LOCAL_INCLUDES += [
'..',
]

if CONFIG['GNU_CXX']:
CXXFLAGS += ['-Wshadow']
Loading

0 comments on commit e56b759

Please sign in to comment.