diff options
Diffstat (limited to 'lib')
-rw-r--r-- | lib/spack/spack/spec.py | 2 | ||||
-rw-r--r-- | lib/spack/spack/test/spec_semantics.py | 1 |
2 files changed, 2 insertions, 1 deletions
diff --git a/lib/spack/spack/spec.py b/lib/spack/spack/spec.py index 1605152450..e29e3b2f85 100644 --- a/lib/spack/spack/spec.py +++ b/lib/spack/spack/spec.py @@ -4333,7 +4333,7 @@ class Spec(object): if callable(current): raise SpecFormatStringError("Attempted to format callable object") - if not current: + if current is None: # We're not printing anything return diff --git a/lib/spack/spack/test/spec_semantics.py b/lib/spack/spack/test/spec_semantics.py index bd75261222..1a6a08b41e 100644 --- a/lib/spack/spack/test/spec_semantics.py +++ b/lib/spack/spack/test/spec_semantics.py @@ -660,6 +660,7 @@ class TestSpecSemantics(object): ("{architecture.os}", "", "os", lambda spec: spec.architecture), ("{architecture.target}", "", "target", lambda spec: spec.architecture), ("{prefix}", "", "prefix", lambda spec: spec), + ("{external}", "", "external", lambda spec: spec), # test we print "False" ] hash_segments = [ |