mirror of
https://github.com/ThePhD/sol2.git
synced 2024-03-22 13:10:44 +08:00
unused variable warnings turned errors killing all the tests
This commit is contained in:
parent
44b4045343
commit
c2b8a9cc57
|
@ -1,6 +1,9 @@
|
|||
optional<T>
|
||||
===========
|
||||
|
||||
This is an implemention of `optional from the standard library`_. If it detects that a proper optional exists, it will attempt to use it. This is mostly an implementation detail, used in the :ref:`sol::stack::check_get<stack-check-get>` and :ref:`sol::stack::get\<optional\<T>><stack-get>` and ``optional<T> maybe_value = table["arf"];`` implementations for additional safety reasons.
|
||||
This is an implemention of `optional from the standard library`_. If it detects that a proper optional exists, it will attempt to use it. This is mostly an implementation detail, used in the :ref:`sol::stack::check_get<stack-check-get>` and :ref:`sol::stack::get\<optional\<T>><stack-get>` and ``sol::optional<T> maybe_value = table["arf"];`` implementations for additional safety reasons.
|
||||
|
||||
See `this example here`_ for a demonstration on how to use it and other features!
|
||||
|
||||
.. _optional from the standard library: http://en.cppreference.com/w/cpp/utility/optional
|
||||
.. _this example here: https://github.com/ThePhD/sol2/blob/develop/examples/optional_with_iteration.cpp
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
#include <memory>
|
||||
#include <iostream>
|
||||
|
||||
int main(int argc, char** argv) {
|
||||
int main(int, char**) {
|
||||
std::cout << "=== optional and iteration example ===" << std::endl;
|
||||
|
||||
struct thing {
|
||||
|
|
Loading…
Reference in New Issue
Block a user