]>
Commit | Line | Data |
---|---|---|
7c673cae FG |
1 | <?xml version="1.0" encoding="utf-8"?> |
2 | <!-- | |
3 | Copyright 2012 Eric Niebler | |
4 | ||
5 | Distributed under the Boost | |
6 | Software License, Version 1.0. (See accompanying | |
7 | file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) | |
8 | --> | |
9 | <header name="boost/proto/deep_copy.hpp"> | |
10 | <para>Replace all nodes stored by reference by nodes stored by value.</para> | |
11 | <namespace name="boost"> | |
12 | <namespace name="proto"> | |
13 | ||
14 | <namespace name="result_of"> | |
15 | <!-- proto::result_of::deep_copy --> | |
16 | <struct name="deep_copy"> | |
17 | <template> | |
18 | <template-type-parameter name="Expr"/> | |
19 | </template> | |
20 | <purpose>A metafunction for calculating the return type of <computeroutput> | |
21 | <functionname alt="proto::deep_copy">proto::deep_copy()</functionname></computeroutput>.</purpose> | |
22 | <description> | |
23 | <para> | |
24 | A metafunction for calculating the return type of <computeroutput> | |
25 | <functionname alt="proto::deep_copy">proto::deep_copy()</functionname></computeroutput>. The type | |
26 | parameter <computeroutput>Expr</computeroutput> should be the type of a Proto expression tree. | |
27 | It should not be a reference type, nor should it be cv-qualified. | |
28 | </para> | |
29 | </description> | |
30 | <typedef name="type"> | |
31 | <type><emphasis>unspecified</emphasis></type> | |
32 | </typedef> | |
33 | </struct> | |
34 | </namespace> | |
35 | ||
36 | <namespace name="functional"> | |
37 | <!-- proto::functional::deep_copy --> | |
38 | <struct name="deep_copy"> | |
39 | <inherit> | |
40 | <type><classname>proto::callable</classname></type> | |
41 | </inherit> | |
42 | <purpose>A <conceptname>PolymorphicFunctionObject</conceptname> type for deep-copying Proto | |
43 | expression trees.</purpose> | |
44 | <description> | |
45 | <para> | |
46 | A <conceptname>PolymorphicFunctionObject</conceptname> type for deep-copying Proto expression trees. | |
47 | When a tree is deep-copied, all internal nodes and terminals held by reference are instead held by value. | |
48 | The only exception is function references, which continue to be held by reference. | |
49 | </para> | |
50 | </description> | |
51 | <struct-specialization name="result"> | |
52 | <template> | |
53 | <template-type-parameter name="This"/> | |
54 | <template-type-parameter name="Expr"/> | |
55 | </template> | |
56 | <specialization> | |
57 | <template-arg>This(Expr)</template-arg> | |
58 | </specialization> | |
59 | <inherit> | |
60 | <type><classname>result_of::deep_copy</classname><Expr></type> | |
61 | </inherit> | |
62 | </struct-specialization> | |
63 | <method-group name="public member functions"> | |
64 | <method name="operator()" cv="const"> | |
65 | <type><classname>result_of::deep_copy</classname><Expr>::type</type> | |
66 | <template> | |
67 | <template-type-parameter name="Expr"/> | |
68 | </template> | |
69 | <parameter name="expr"> | |
70 | <paramtype>Expr const &</paramtype> | |
71 | </parameter> | |
72 | <purpose>Deep-copies a Proto expression tree, turning all nodes and terminals held by | |
73 | reference into ones held by value.</purpose> | |
74 | </method> | |
75 | </method-group> | |
76 | </struct> | |
77 | </namespace> | |
78 | ||
79 | <!-- proto::deep_copy() --> | |
80 | <function name="deep_copy"> | |
81 | <type>typename <classname>proto::result_of::deep_copy</classname><Expr>::type</type> | |
82 | <template> | |
83 | <template-type-parameter name="Expr"/> | |
84 | </template> | |
85 | <parameter name="expr"> | |
86 | <paramtype>Expr const &</paramtype> | |
87 | </parameter> | |
88 | <purpose>A function for deep-copying Proto expression trees. </purpose> | |
89 | <description> | |
90 | <para> | |
91 | A function for deep-copying Proto expression trees. When a tree is deep-copied, all internal | |
92 | nodes and terminals held by reference are instead held by value.</para> | |
93 | </description> | |
94 | <notes> | |
95 | <para> | |
96 | Terminals of reference-to-function type are left unchanged. | |
97 | </para> | |
98 | <para> | |
99 | Equivalent to <computeroutput><classname>proto::functional::deep_copy</classname>()(expr) | |
100 | </computeroutput>. | |
101 | </para> | |
102 | </notes> | |
103 | </function> | |
104 | </namespace> | |
105 | </namespace> | |
106 | </header> |