cleanup: Unbound local variable

pull/1315/head
Mike Sinkovsky 8 years ago committed by Jussi Pakkanen
parent c9423cc3a8
commit dac8351ff1
  1. 1
      mesonbuild/backend/vs2010backend.py
  2. 1
      tools/cmake2meson.py

@ -882,7 +882,6 @@ class Vs2010Backend(backends.Backend):
header, impl, suffix = pch_sources[lang] header, impl, suffix = pch_sources[lang]
relpath = os.path.join(proj_to_src_dir, impl) relpath = os.path.join(proj_to_src_dir, impl)
inc_cl = ET.SubElement(inc_src, 'CLCompile', Include=relpath) inc_cl = ET.SubElement(inc_src, 'CLCompile', Include=relpath)
lang = Vs2010Backend.lang_from_source_file(s)
pch = ET.SubElement(inc_cl, 'PrecompiledHeader') pch = ET.SubElement(inc_cl, 'PrecompiledHeader')
pch.text = 'Create' pch.text = 'Create'
pch_out = ET.SubElement(inc_cl, 'PrecompiledHeaderOutputFile') pch_out = ET.SubElement(inc_cl, 'PrecompiledHeaderOutputFile')

@ -278,6 +278,7 @@ class Converter:
for o in self.options: for o in self.options:
(optname, description, default) = o (optname, description, default) = o
if default is None: if default is None:
typestr = ''
defaultstr = '' defaultstr = ''
else: else:
if default == 'OFF': if default == 'OFF':

Loading…
Cancel
Save