diff options
author | Isuru Fernando <isuruf@gmail.com> | 2018-07-08 11:13:18 -0600 |
---|---|---|
committer | Isuru Fernando <isuruf@gmail.com> | 2018-07-08 11:13:18 -0600 |
commit | c8de2f5dd31a36208f183371d5ad9d6a90135fce (patch) | |
tree | a998237ae9b727230ff9c74408a233f46d5d9285 /numpy/distutils/fcompiler/environment.py | |
parent | 65687ff01c932b53d641fbe91b8d945d1a550744 (diff) | |
download | numpy-c8de2f5dd31a36208f183371d5ad9d6a90135fce.tar.gz |
Simplify logic
Diffstat (limited to 'numpy/distutils/fcompiler/environment.py')
-rw-r--r-- | numpy/distutils/fcompiler/environment.py | 13 |
1 files changed, 2 insertions, 11 deletions
diff --git a/numpy/distutils/fcompiler/environment.py b/numpy/distutils/fcompiler/environment.py index 37012dbb2..489784580 100644 --- a/numpy/distutils/fcompiler/environment.py +++ b/numpy/distutils/fcompiler/environment.py @@ -54,17 +54,8 @@ class EnvironmentConfig(object): if envvar is not None: envvar_contents = os.environ.get(envvar) if envvar_contents is not None: - if convert is not None: - envvar_contents = convert(envvar_contents) - else: - envvar_contents = [envvar_contents] - if append and os.environ.get('NPY_DISTUTILS_APPEND_FLAGS', '0') == '1': - if var is None: - var = '' - try: - var = ' '.join(var + envvar_contents) - except TypeError: - var = ' '.join([var] + envvar_contents) + if var and append and os.environ.get('NPY_DISTUTILS_APPEND_FLAGS', '0') == '1': + var = var + [envvar_contents] else: var = envvar_contents if confvar is not None and self._conf: |