Review fixes.

pull/1457/head
Jussi Pakkanen 8 years ago
parent 319398f074
commit 553ac89e02
  1. 2
      mesonbuild/backend/backends.py
  2. 2
      mesonbuild/backend/ninjabackend.py
  3. 2
      mesonbuild/backend/vs2010backend.py
  4. 3
      mesonbuild/coredata.py

@ -83,7 +83,7 @@ class OptionProxy:
class OptionOverrideProxy:
'''Mimic an option list but transparently override
selected option values.'''
selected option values.'''
def __init__(self, overrides, options):
self.overrides = overrides
self.options = options

@ -1890,8 +1890,6 @@ rule FORTRAN_DEP_HACK
raise AssertionError('BUG: sources should not contain headers {!r}'.format(src))
if isinstance(src, RawFilename) and src.fname.endswith('.h'):
raise AssertionError('BUG: sources should not contain headers {!r}'.format(src.fname))
extra_orderdeps = []
compiler = get_compiler_for_source(target.compilers.values(), src)
if isinstance(src, str) and src.endswith('.h'):
raise AssertionError('BUG: sources should not contain headers {!r}'.format(src))

@ -6,7 +6,7 @@
# http://www.apache.org/licenses/LICENSE-2.0
# Unless required by applicable law or agreed to in writingget_, software
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and

@ -16,6 +16,7 @@ import pickle, os, uuid
from pathlib import PurePath
from .mesonlib import MesonException, commonpath
from .mesonlib import default_libdir, default_libexecdir, default_prefix
import ast
version = '0.40.0.dev1'
backendlist = ['ninja', 'vs', 'vs2010', 'vs2015', 'vs2017', 'xcode']
@ -113,7 +114,7 @@ class UserStringArrayOption(UserOption):
if isinstance(value, str):
if not value.startswith('['):
raise MesonException('Valuestring does not define an array: ' + value)
newvalue = eval(value, {}, {}) # Yes, it is unsafe.
newvalue = ast.literal_eval(value)
else:
newvalue = value
if not isinstance(newvalue, list):

Loading…
Cancel
Save