summaryrefslogtreecommitdiff
path: root/buildstream/utils.py
diff options
context:
space:
mode:
authorTristan Maat <tm@tlater.net>2018-04-06 12:16:52 +0000
committerTristan Maat <tm@tlater.net>2018-04-06 15:01:14 +0000
commit55aedba17f8a8ac676fe18cbdd2d4b6fef202eda (patch)
tree584f4a40d8a64f656f5a4209403e17d899d1d9a7 /buildstream/utils.py
parent23edfe5d961136c2a22fd4c0939bb9dc0e9e3a14 (diff)
downloadbuildstream-node-get-default.tar.gz
Allow 'None' as a default_value for _yaml.node_getnode-get-default
Diffstat (limited to 'buildstream/utils.py')
-rw-r--r--buildstream/utils.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/buildstream/utils.py b/buildstream/utils.py
index 209e9d094..40705346b 100644
--- a/buildstream/utils.py
+++ b/buildstream/utils.py
@@ -532,6 +532,11 @@ def save_file_atomic(filename, mode='w', *, buffering=-1, encoding=None,
raise
+# A sentinel to be used as a default argument for functions that need
+# to distinguish between a kwarg set to None and an unset kwarg.
+_sentinel = object()
+
+
# Recursively remove directories, ignoring file permissions as much as
# possible.
def _force_rmtree(rootpath, **kwargs):