summaryrefslogtreecommitdiff
path: root/doc/html/move.html
blob: 926f876207b6a9cb102d063ac0530ca30cc78714 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=US-ASCII">
<title>Chapter&#160;16.&#160;Boost.Move</title>
<link rel="stylesheet" href="../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.76.1">
<link rel="home" href="index.html" title="The Boost C++ Libraries BoostBook Documentation Subset">
<link rel="up" href="libraries.html" title="Part&#160;I.&#160;The Boost C++ Libraries (BoostBook Subset)">
<link rel="prev" href="boost_lexical_cast/performance.html" title="Performance">
<link rel="next" href="move/introduction.html" title="Introduction">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../boost.png"></td>
<td align="center"><a href="../../index.html">Home</a></td>
<td align="center"><a href="../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="boost_lexical_cast/performance.html"><img src="../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="libraries.html"><img src="../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="index.html"><img src="../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="move/introduction.html"><img src="../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="chapter">
<div class="titlepage"><div>
<div><h2 class="title">
<a name="move"></a>Chapter&#160;16.&#160;Boost.Move</h2></div>
<div><div class="author"><h3 class="author">
<span class="firstname">Ion</span> <span class="surname">Gaztanaga</span>
</h3></div></div>
<div><p class="copyright">Copyright &#169; 2008-2010 Ion Gaztanaga</p></div>
<div><div class="legalnotice">
<a name="move.legal"></a><p>
        Distributed under the Boost Software License, Version 1.0. (See accompanying
        file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
      </p>
</div></div>
</div></div>
<div class="toc">
<p><b>Table of Contents</b></p>
<dl>
<dt><span class="section"><a href="move.html#move.what_is_boost_move">What is Boost.Move?</a></span></dt>
<dt><span class="section"><a href="move/introduction.html">Introduction</a></span></dt>
<dt><span class="section"><a href="move/implementing_movable_classes.html">Implementing copyable
    and movable classes</a></span></dt>
<dd><dl>
<dt><span class="section"><a href="move/implementing_movable_classes.html#move.implementing_movable_classes.copyable_and_movable_cpp0x">Copyable
      and movable classes in C++0x</a></span></dt>
<dt><span class="section"><a href="move/implementing_movable_classes.html#move.implementing_movable_classes.copyable_and_movable_cpp03">Copyable
      and movable classes in portable syntax for both C++03 and C++0x compilers</a></span></dt>
</dl></dd>
<dt><span class="section"><a href="move/composition_inheritance.html">Composition or inheritance</a></span></dt>
<dt><span class="section"><a href="move/movable_only_classes.html">Movable but Non-Copyable Types</a></span></dt>
<dt><span class="section"><a href="move/move_and_containers.html">Containers and move semantics</a></span></dt>
<dt><span class="section"><a href="move/construct_forwarding.html">Constructor Forwarding</a></span></dt>
<dt><span class="section"><a href="move/move_iterator.html">Move iterators</a></span></dt>
<dt><span class="section"><a href="move/move_inserters.html">Move inserters</a></span></dt>
<dt><span class="section"><a href="move/move_algorithms.html">Move algorithms</a></span></dt>
<dt><span class="section"><a href="move/emulation_limitations.html">Emulation limitations</a></span></dt>
<dd><dl>
<dt><span class="section"><a href="move/emulation_limitations.html#move.emulation_limitations.emulation_limitations_base">Initializing
      base classes</a></span></dt>
<dt><span class="section"><a href="move/emulation_limitations.html#move.emulation_limitations.template_parameters">Template
      parameters for perfect forwarding</a></span></dt>
<dt><span class="section"><a href="move/emulation_limitations.html#move.emulation_limitations.emulation_limitations_binding">Binding
      of rvalue references to lvalues</a></span></dt>
<dt><span class="section"><a href="move/emulation_limitations.html#move.emulation_limitations.assignment_operator">Assignment
      operator in classes derived from or holding copyable and movable types</a></span></dt>
</dl></dd>
<dt><span class="section"><a href="move/how_the_library_works.html">How the library works</a></span></dt>
<dt><span class="section"><a href="move/thanks_to.html">Thanks and credits</a></span></dt>
<dt><span class="section"><a href="move/release_notes.html">Release Notes</a></span></dt>
<dd><dl><dt><span class="section"><a href="move/release_notes.html#move.release_notes.release_notes_boost_1_49_00">Boost
      1.49 Release</a></span></dt></dl></dd>
<dt><span class="section"><a href="move/reference.html">Reference</a></span></dt>
<dd><dl><dt><span class="section"><a href="move/reference.html#header.boost.move.move_hpp">Header &lt;boost/move/move.hpp&gt;</a></span></dt></dl></dd>
</dl>
</div>
<div class="important"><table border="0" summary="Important">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Important]" src="../../doc/src/images/important.png"></td>
<th align="left">Important</th>
</tr>
<tr><td align="left" valign="top"><p>
      To be able to use containers of movable-only values you will need to use containers
      supporting move semantics, like <span class="bold"><strong>Boost.Container</strong></span>
      containers
    </p></td></tr>
</table></div>
<div class="note"><table border="0" summary="Note">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Note]" src="../../doc/src/images/note.png"></td>
<th align="left">Note</th>
</tr>
<tr><td align="left" valign="top"><p>
      Tested compilers: MSVC-7.1, 8.0, 9.0, GCC 4.3-MinGW in C++03 and C++0x modes,
      Intel 10.1
    </p></td></tr>
</table></div>
<div class="section">
<div class="titlepage"><div><div><h2 class="title" style="clear: both">
<a name="move.what_is_boost_move"></a><a class="link" href="move.html#move.what_is_boost_move" title="What is Boost.Move?">What is Boost.Move?</a>
</h2></div></div></div>
<p>
      Rvalue references are a major C++0x feature, enabling move semantics for C++
      values. However, we don't need C++0x compilers to take advantage of move semanatics.
      <span class="bold"><strong>Boost.Move</strong></span> emulates C++0x move semantics in
      C++03 compilers and allows writing portable code that works optimally in C++03
      and C++0x compilers.
    </p>
</div>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"><p><small>Last revised: February 20, 2012 at 20:50:17 GMT</small></p></td>
<td align="right"><div class="copyright-footer"></div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="boost_lexical_cast/performance.html"><img src="../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="libraries.html"><img src="../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="index.html"><img src="../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="move/introduction.html"><img src="../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>