|
Boost-Commit : |
Subject: [Boost-commit] svn:boost r72146 - sandbox/block_ptr/libs/smart_ptr/doc
From: phil_at_[hidden]
Date: 2011-05-24 20:24:48
Author: pbouchard
Date: 2011-05-24 20:24:47 EDT (Tue, 24 May 2011)
New Revision: 72146
URL: http://svn.boost.org/trac/boost/changeset/72146
Log:
* Raw pointer doc
Text files modified:
sandbox/block_ptr/libs/smart_ptr/doc/tutorial.html | 13 +++++++++++++
1 files changed, 13 insertions(+), 0 deletions(-)
Modified: sandbox/block_ptr/libs/smart_ptr/doc/tutorial.html
==============================================================================
--- sandbox/block_ptr/libs/smart_ptr/doc/tutorial.html (original)
+++ sandbox/block_ptr/libs/smart_ptr/doc/tutorial.html 2011-05-24 20:24:47 EDT (Tue, 24 May 2011)
@@ -127,6 +127,19 @@
</tr>
</table>
+ <p>Thirdly creating pointee objects in a faster way is possible by calling <i>operator new</i> directly:</p>
+
+ <pre>
+ block_ptr<int> p = new int(10);
+ </pre>
+
+ <table>
+ <tr>
+ <td width="20"></td>
+ <td><i>Note: The assignment of a raw pointer needs to be immediate.</i></td>
+ </tr>
+ </table>
+
<h2><a name="caveat" id="caveat"></a>Caveat</h2>
<p>Hierarchies with multiple inheritance without virtual tables will cause undefined behavior if a pointer to a derived class is assigned to a pointer of one
Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk