An open API service indexing awesome lists of open source software.

https://github.com/lb--/optional

My personal implementation of the optional wrapper in C++.
https://github.com/lb--/optional

Last synced: 12 months ago
JSON representation

My personal implementation of the optional wrapper in C++.

Awesome Lists containing this project

README

          

optional [![travis](https://travis-ci.org/LB--/optional.svg?branch=optional)](https://travis-ci.org/LB--/optional)
========
My personal implementation of `std::optional`/`boost::optional`, just for fun.

## Usage
### CMake
From the `cmake` directory, copy the `FindLB` directory to a place in your `CMAKE_MODULE_PATH`.
Then, add `find_package(LB/optional REQUIRED)` to your CMake script.
You may need to set the CMake variable `LB/optional_ROOT` if you installed to a nonstandard location.
Finally, link to the `LB::optional` imported target with `target_link_libraries()`.

### C++
First `#include `, and then bug LB to finish this TODO.