mirror of
https://github.com/boostorg/core.git
synced 2025-11-29 13:50:10 +01:00
Add use_default to Core
This commit is contained in:
@@ -58,3 +58,4 @@ criteria for inclusion is that the utility component be:
|
||||
[include swap.qbk]
|
||||
[include typeinfo.qbk]
|
||||
[include uncaught_exceptions.qbk]
|
||||
[include use_default.qbk]
|
||||
|
||||
47
doc/use_default.qbk
Normal file
47
doc/use_default.qbk
Normal file
@@ -0,0 +1,47 @@
|
||||
[/
|
||||
Copyright 2019 Glen Joseph Fernandes
|
||||
(glenjofe@gmail.com)
|
||||
|
||||
Distributed under the Boost Software License, Version 1.0.
|
||||
(http://www.boost.org/LICENSE_1_0.txt)
|
||||
]
|
||||
|
||||
[section:use_default use_default]
|
||||
|
||||
[section Overview]
|
||||
|
||||
The header <boost/core/use_default.hpp> provides the type `boost::use_default`
|
||||
which is used by other Boost libraries as a sentinel type in a templates to
|
||||
indicate defaults.
|
||||
|
||||
[endsect]
|
||||
|
||||
[section Example]
|
||||
|
||||
```
|
||||
template<class Derived, class Base,
|
||||
class Value = boost::use_default,
|
||||
class CategoryOrTraversal = boost::use_default,
|
||||
class Reference = boost::use_default,
|
||||
class Difference = boost::use_default>
|
||||
class iterator_adaptor;
|
||||
|
||||
template<class Value>
|
||||
class node_iterator
|
||||
: public iterator_adaptor<node_iterator<Value>, Value*,
|
||||
boost::use_default, boost::forward_traversal_tag>;
|
||||
```
|
||||
|
||||
[endsect]
|
||||
|
||||
[section Reference]
|
||||
|
||||
```
|
||||
namespace boost {
|
||||
struct use_default { };
|
||||
}
|
||||
```
|
||||
|
||||
[endsect]
|
||||
|
||||
[endsect]
|
||||
Reference in New Issue
Block a user