diff options
author | Benjamin Schubert <contact@benschubert.me> | 2019-06-25 20:27:15 +0100 |
---|---|---|
committer | bst-marge-bot <marge-bot@buildstream.build> | 2019-07-15 14:14:03 +0000 |
commit | 42d3d8406a15cd5f6f4a7d00e298dba019a50ed6 (patch) | |
tree | 7165dafdc3707faf4e71fba8c81d5752fd4668d8 /src/buildstream/_yaml.pyx | |
parent | ed2dde6110a5f9087ff3596df9d86ba5468dcac8 (diff) | |
download | buildstream-42d3d8406a15cd5f6f4a7d00e298dba019a50ed6.tar.gz |
_yaml: Introduce 'MappingNode.values()'
This is to mimic the 'dict.values()' interface.
- Adapt parts of the code calling 'node_items' but ignoring the
first value to use this instead
Diffstat (limited to 'src/buildstream/_yaml.pyx')
-rw-r--r-- | src/buildstream/_yaml.pyx | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/buildstream/_yaml.pyx b/src/buildstream/_yaml.pyx index 63ebd6e68..a00691b0e 100644 --- a/src/buildstream/_yaml.pyx +++ b/src/buildstream/_yaml.pyx @@ -238,6 +238,9 @@ cdef class MappingNode(Node): except KeyError: pass + cpdef object values(self): + return self.value.values() + def __delitem__(self, str key): del self.value[key] |