diff options
author | Boris Kolpackov <boris@codesynthesis.com> | 2016-07-20 16:18:29 +0200 |
---|---|---|
committer | Boris Kolpackov <boris@codesynthesis.com> | 2016-07-20 16:18:29 +0200 |
commit | de15b95d09d00821aa23e96a0c3e827689c27a58 (patch) | |
tree | c5631a106fe28ef29a25b03e98c2590fbe867804 /build2/dump.cxx | |
parent | df43058115b389f1375690812ad92301288f976f (diff) |
Switch to dynamic empty() implementation in variable value
The current model fell apart when we modified values directly.
Diffstat (limited to 'build2/dump.cxx')
-rw-r--r-- | build2/dump.cxx | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/build2/dump.cxx b/build2/dump.cxx index 08700fc..7cb97ef 100644 --- a/build2/dump.cxx +++ b/build2/dump.cxx @@ -22,7 +22,7 @@ namespace build2 { // First print attributes if any. // - bool a (v.null () || (type && v.type != nullptr)); + bool a (!v || (type && v.type != nullptr)); if (a) os << '['; @@ -35,7 +35,7 @@ namespace build2 s = " "; } - if (v.null ()) + if (!v) { os << s << "null"; s = " "; @@ -46,7 +46,7 @@ namespace build2 // Now the value if there is one. // - if (!v.null ()) + if (v) { names storage; os << (a ? " " : "") << reverse (v, storage); |