summaryrefslogtreecommitdiff
path: root/lib/containers/optional.go
diff options
context:
space:
mode:
Diffstat (limited to 'lib/containers/optional.go')
-rw-r--r--lib/containers/optional.go10
1 files changed, 10 insertions, 0 deletions
diff --git a/lib/containers/optional.go b/lib/containers/optional.go
new file mode 100644
index 0000000..3055308
--- /dev/null
+++ b/lib/containers/optional.go
@@ -0,0 +1,10 @@
+// Copyright (C) 2022 Luke Shumaker <lukeshu@lukeshu.com>
+//
+// SPDX-License-Identifier: GPL-2.0-or-later
+
+package containers
+
+type Optional[T any] struct {
+ OK bool
+ Val T
+}