|
Boost-Commit : |
From: asutton_at_[hidden]
Date: 2007-07-24 20:32:09
Author: asutton
Date: 2007-07-24 20:32:09 EDT (Tue, 24 Jul 2007)
New Revision: 7527
URL: http://svn.boost.org/trac/boost/changeset/7527
Log:
Added a destructible concept
Added:
sandbox/boost_docs/trunk/libs/standard/doc/concepts/utilities/destructible.qbk
Text files modified:
sandbox/boost_docs/trunk/libs/standard/doc/concepts/utilities/copy_constructible.qbk | 3 +++
sandbox/boost_docs/trunk/libs/standard/doc/concepts/utilities/utilities.qbk | 1 +
sandbox/boost_docs/trunk/libs/standard/doc/std.qbk | 1 +
3 files changed, 5 insertions(+), 0 deletions(-)
Modified: sandbox/boost_docs/trunk/libs/standard/doc/concepts/utilities/copy_constructible.qbk
==============================================================================
--- sandbox/boost_docs/trunk/libs/standard/doc/concepts/utilities/copy_constructible.qbk (original)
+++ sandbox/boost_docs/trunk/libs/standard/doc/concepts/utilities/copy_constructible.qbk 2007-07-24 20:32:09 EDT (Tue, 24 Jul 2007)
@@ -12,6 +12,9 @@
argument: a `const` reference to `T`. After construction, a constructed
object is equivalent to the object passed as an argument.
+[heading Refinement of]
+[StdDestructible]
+
[heading Notation]
The following expressions are used within this document:
[table
Added: sandbox/boost_docs/trunk/libs/standard/doc/concepts/utilities/destructible.qbk
==============================================================================
--- (empty file)
+++ sandbox/boost_docs/trunk/libs/standard/doc/concepts/utilities/destructible.qbk 2007-07-24 20:32:09 EDT (Tue, 24 Jul 2007)
@@ -0,0 +1,44 @@
+[/
+ / Copyright (c) 2007 Andrew Sutton
+ /
+ / Distributed under the Boost Software License, Version 1.0. (See accompanying
+ / file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
+ /]
+
+[section Copy Constructible]
+A type `T` is /destructible/ if it has a public destructor. The
+destructor can be either compiler-generated or user-defined.
+
+[heading Notation]
+The following expressions are used within this document:
+[table
+ [[Expression] [Description]]
+ [[T] [A [StdCopyConstructible] type.]]
+ [[t] [An object of type `T`.]]
+]
+
+[heading Requirements]
+[table
+ [[Name] [Expression] [Result Type] [Description]]
+ [
+ [Destructor]
+ [`t.~T()`]
+ []
+ [
+ *Semantics:* The destructor of `t` is called, destroying
+ the object.
+ ]
+ ]
+]
+
+[heading C++0x]
+The [StdDestructible] concept will be defined as:
+
+ // The Destructible concept requires a public desctructor,
+ // either compiler-generated or user-define.
+ auto concept Destructible<typename T>
+ {
+ T::~T();
+ };
+
+[endsect]
\ No newline at end of file
Modified: sandbox/boost_docs/trunk/libs/standard/doc/concepts/utilities/utilities.qbk
==============================================================================
--- sandbox/boost_docs/trunk/libs/standard/doc/concepts/utilities/utilities.qbk (original)
+++ sandbox/boost_docs/trunk/libs/standard/doc/concepts/utilities/utilities.qbk 2007-07-24 20:32:09 EDT (Tue, 24 Jul 2007)
@@ -8,6 +8,7 @@
Utility concepts include concepts that can be applied to almost
any data type (both built-in and user-defined).
+[include destructible.qbk]
[include default_constructible.qbk]
[include copy_constructible.qbk]
[include assignable.qbk]
Modified: sandbox/boost_docs/trunk/libs/standard/doc/std.qbk
==============================================================================
--- sandbox/boost_docs/trunk/libs/standard/doc/std.qbk (original)
+++ sandbox/boost_docs/trunk/libs/standard/doc/std.qbk 2007-07-24 20:32:09 EDT (Tue, 24 Jul 2007)
@@ -20,6 +20,7 @@
]
[/ Quick Reference Templates /]
+[template StdDestructible[] [link standards.concepts.utilities.destructible [^Destructible]]]
[template StdDefaultConstructible[] [link standard.concepts.utilities.default_constructible [^DefaultConstructible]]]
[template StdCopyConstructible[] [link standard.concepts.utilities.copy_constructible [^CopyConstructible]]]
[template StdAssignable[] [link standard.concepts.utilities.assignable [^Assignable]]]
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