summaryrefslogtreecommitdiffstats
path: root/src/boost/libs/optional/README.md
diff options
context:
space:
mode:
Diffstat (limited to 'src/boost/libs/optional/README.md')
-rw-r--r--src/boost/libs/optional/README.md15
1 files changed, 15 insertions, 0 deletions
diff --git a/src/boost/libs/optional/README.md b/src/boost/libs/optional/README.md
new file mode 100644
index 000000000..4f73388d1
--- /dev/null
+++ b/src/boost/libs/optional/README.md
@@ -0,0 +1,15 @@
+optional
+========
+
+A library for representing optional (nullable) objects in C++.
+
+```cpp
+optional<int> readInt(); // this function may return either an int or a not-an-int
+
+if (optional<int> oi = readInt()) // did I get a real int
+ cout << "my int is: " << *oi; // use my int
+else
+ cout << "I have no int";
+```
+
+For more information refer to the documentation provided with this library.