Skip to content

Commit

Permalink
Yet another step in the neverending saga of -Wpedantic.
Browse files Browse the repository at this point in the history
  • Loading branch information
jpakkane committed Nov 22, 2015
1 parent e33cf31 commit 1caf7e6
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 10 deletions.
16 changes: 7 additions & 9 deletions compilers.py
Original file line number Diff line number Diff line change
Expand Up @@ -1125,7 +1125,7 @@ def __init__(self, exelist, version, gcc_type, is_cross, exe_wrapper=None):
self.id = 'gcc'
self.gcc_type = gcc_type
self.warn_args = {'1': ['-Wall', '-Winvalid-pch'],
'2': ['-Wall', '-Wpedantic', '-Winvalid-pch'],
'2': ['-Wall', '-Wextra', '-Winvalid-pch'],
'3' : ['-Wall', '-Wpedantic', '-Wextra', '-Winvalid-pch']}

def get_pic_args(self):
Expand Down Expand Up @@ -1187,7 +1187,7 @@ def __init__(self, exelist, version, is_cross, exe_wrapper=None):
# if this breaks your use case.
self.gcc_type = GCC_STANDARD
self.warn_args = {'1': ['-Wall', '-Winvalid-pch'],
'2': ['-Wall', '-Wpedantic', '-Winvalid-pch'],
'2': ['-Wall', '-Wextra', '-Winvalid-pch'],
'3' : ['-Wall', '-Wpedantic', '-Wextra', '-Winvalid-pch']}

def get_buildtype_args(self, buildtype):
Expand All @@ -1212,7 +1212,7 @@ def __init__(self, exelist, version, is_cross, exe_wrapper=None):
# if this breaks your use case.
self.gcc_type = GCC_STANDARD
self.warn_args = {'1': ['-Wall', '-Winvalid-pch', '-Wnon-virtual-dtor'],
'2': ['-Wall', '-Wpedantic', '-Winvalid-pch', '-Wnon-virtual-dtor'],
'2': ['-Wall', '-Wextra', '-Winvalid-pch', '-Wnon-virtual-dtor'],
'3' : ['-Wall', '-Wpedantic', '-Wextra', '-Winvalid-pch', '-Wnon-virtual-dtor']}

def get_buildtype_args(self, buildtype):
Expand All @@ -1238,13 +1238,11 @@ def __init__(self, exelist, version, is_cross, exe_wrapper=None):
self.id = 'clang'

class ClangCCompiler(CCompiler):
std_warn_args = ['-Wall', '-Wpedantic', '-Winvalid-pch']

def __init__(self, exelist, version, is_cross, exe_wrapper=None):
CCompiler.__init__(self, exelist, version, is_cross, exe_wrapper)
self.id = 'clang'
self.warn_args = {'1': ['-Wall', '-Winvalid-pch'],
'2': ['-Wall', '-Wpedantic', '-Winvalid-pch'],
'2': ['-Wall', '-Wextra', '-Winvalid-pch'],
'3' : ['-Weverything']}

def get_buildtype_args(self, buildtype):
Expand Down Expand Up @@ -1288,8 +1286,8 @@ def __init__(self, exelist, version, gcc_type, is_cross, exe_wrap):
CPPCompiler.__init__(self, exelist, version, is_cross, exe_wrap)
self.id = 'gcc'
self.gcc_type = gcc_type
self.warn_args = {'1': ['-Wall', '-Winvalid-pch'],
'2': ['-Wall', '-Wpedantic', '-Winvalid-pch', '-Wnon-virtual-dtor'],
self.warn_args = {'1': ['-Wall', '-Winvalid-pch', '-Wnon-virtual-dtor'],
'2': ['-Wall', '-Wextra', '-Winvalid-pch', '-Wnon-virtual-dtor'],
'3': ['-Wall', '-Wpedantic', '-Wextra', '-Winvalid-pch', '-Wnon-virtual-dtor']}

def get_always_args(self):
Expand Down Expand Up @@ -1335,7 +1333,7 @@ def __init__(self, exelist, version, is_cross, exe_wrapper=None):
CPPCompiler.__init__(self, exelist, version, is_cross, exe_wrapper)
self.id = 'clang'
self.warn_args = {'1': ['-Wall', '-Winvalid-pch', '-Wnon-virtual-dtor'],
'2': ['-Wall', '-Wpedantic', '-Winvalid-pch', '-Wnon-virtual-dtor'],
'2': ['-Wall', '-Wextra', '-Winvalid-pch', '-Wnon-virtual-dtor'],
'3': ['-Weverything']}

def get_buildtype_args(self, buildtype):
Expand Down
2 changes: 1 addition & 1 deletion meson.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@

parser = argparse.ArgumentParser()

default_warning = '2'
default_warning = '1'

if mesonlib.is_windows():
def_prefix = 'c:/'
Expand Down

0 comments on commit 1caf7e6

Please sign in to comment.