Fixed placeholder compatibility with Boost 1.34.
[luabind.git] / doc / discard_result.rst
blobd148d205836b358361ec39738ddaceb1fb007be9
1 discard_result
2 ----------------
4 Motivation
5 ~~~~~~~~~~
7 This is a very simple policy which makes it possible to throw away 
8 the value returned by a C++ function, instead of converting it to 
9 Lua.
11 Defined in
12 ~~~~~~~~~~
14 .. parsed-literal::
16     #include <luabind/discard_result_policy.hpp>
18 Synopsis
19 ~~~~~~~~
21 .. parsed-literal::
23     discard_result
25 Example
26 ~~~~~~~
28 .. parsed-literal::
30     struct X
31     {
32         X& set(T n)
33         {
34             ...
35             return \*this;
36         }
37     };
39     ...
41     module(L)
42     [
43         class_<X>("X")
44             .def("set", &simple::set, **discard_result**)
45     ];