tree-wide: remove unused variables

./mesonbuild/scripts/regen_checker.py:35:5: F841 local variable 'scriptdir' is assigned to but never used
    scriptdir = os.path.split(__file__)[0]
    ^
./mesonbuild/scripts/yelphelper.py:84:13: F841 local variable 'symfile' is assigned to but never used
            symfile = os.path.join(install_dir, m)
            ^
./mesonbuild/backend/backends.py:164:13: F841 local variable 'lang' is assigned to but never used
            lang = comp.get_language()
            ^
./mesonbuild/backend/ninjabackend.py:1286:9: F841 local variable 'scriptdir' is assigned to but never used
        scriptdir = self.environment.get_script_dir()
        ^
./mesonbuild/backend/vs2010backend.py:736:9: F841 local variable 'additional_options_set' is assigned to but never used
        additional_options_set = True
        ^

Signed-off-by: Igor Gnatenko <i.gnatenko.brain@gmail.com>
pull/1233/head
Igor Gnatenko 8 years ago
parent 8268eb4959
commit e611b6748b
  1. 1
      mesonbuild/backend/backends.py
  2. 1
      mesonbuild/backend/ninjabackend.py
  3. 1
      mesonbuild/backend/vs2010backend.py
  4. 1
      mesonbuild/scripts/regen_checker.py
  5. 1
      mesonbuild/scripts/yelphelper.py

@ -161,7 +161,6 @@ class Backend():
# For each language, generate a unity source file and return the list
for comp, srcs in compsrcs.items():
lang = comp.get_language()
with init_language_file(comp.get_default_suffix()) as ofile:
for src in srcs:
ofile.write('#include<%s>\n' % src)

@ -1283,7 +1283,6 @@ int dummy;
outfile.write(command)
outfile.write(description)
outfile.write('\n')
scriptdir = self.environment.get_script_dir()
outfile.write('\n')
symrule = 'rule SHSYM\n'
symcmd = ' command = "%s" "%s" %s %s %s %s $CROSS\n' % (ninja_quote(sys.executable),

@ -733,7 +733,6 @@ class Vs2010Backend(backends.Backend):
if len(target_args) > 0:
target_args.append('%(AdditionalOptions)')
ET.SubElement(clconf, "AdditionalOptions").text = ' '.join(target_args)
additional_options_set = True
for d in target.include_dirs:
for i in d.incdirs:

@ -32,7 +32,6 @@ def need_regen(regeninfo, regen_timestamp):
return False
def regen(regeninfo, mesonscript, backend):
scriptdir = os.path.split(__file__)[0]
cmd = [sys.executable,
mesonscript,
'--internal',

@ -81,7 +81,6 @@ def install_help(srcdir, blddir, sources, media, langs, install_dir, destdir, pr
os.makedirs(os.path.dirname(outfile), exist_ok=True)
os.symlink(srcfile, outfile)
continue
symfile = os.path.join(install_dir, m)
mlog.log('Installing %s to %s.' %(infile, outfile))
if '/' in m or '\\' in m:
os.makedirs(os.path.dirname(outfile), exist_ok=True)

Loading…
Cancel
Save