forked from boostorg/intrusive
no message
[SVN r38076]
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
[library Intrusive
|
||||
[library Boost.Intrusive
|
||||
[quickbook 1.3]
|
||||
[version 2007-05-03]
|
||||
[version 2007-06-23]
|
||||
[authors [Krzikalla, Olaf], [Gaztañaga, Ion]]
|
||||
[copyright 2005 Olaf Krzikalla, 2006-2007 Ion Gaztañaga]
|
||||
[purpose Intrusive containers]
|
||||
@@ -17,7 +17,7 @@
|
||||
|
||||
[*Boost.Intrusive] is a library presenting some intrusive containers to
|
||||
the world of C++. Intrusive containers are special containers
|
||||
that offer [link intrusive.performance better performance]
|
||||
that offer [link boost_intrusive.performance better performance]
|
||||
and exception safety guarantees than non-intrusive containers (like STL containers).
|
||||
|
||||
The performance benefits of intrusive containers makes them ideal as a building
|
||||
@@ -172,7 +172,7 @@ Intrusive containers have also downsides:
|
||||
appropriately. Although this task is easy with [*Boost.Intrusive], touching the
|
||||
definition of a type is sometimes a crucial issue.
|
||||
|
||||
* In intrusive containers you don't store a copy of an object, [*but they rather the origina object
|
||||
* In intrusive containers you don't store a copy of an object, [*but they rather the original object
|
||||
is linked with other objects in the container]. Objects don't need copy-constructors or assignment
|
||||
operators to be stored in intrusive containers. But you have to take care of possible side effects,
|
||||
whenever you change the contents of an object (this is especially important for
|
||||
@@ -183,14 +183,14 @@ Intrusive containers have also downsides:
|
||||
|
||||
* Again you have to be [*careful]: in contrast to STL containers [*it's easy to render an
|
||||
iterator invalid] without touching the intrusive container directly, because the object
|
||||
can be destroyed before is erased from the container.
|
||||
can be disposed before is erased from the container.
|
||||
|
||||
* [*Boost.Intrusive] containers are [*non-copyable and non-assignable]. Since intrusive
|
||||
containers don't have allocation capabilities, these operations have no sense. However,
|
||||
swapping can be used to implement move-capabilities. To ease the implementation of
|
||||
copy constructors and assignment operators of classes storing [*Boost.Intrusive]
|
||||
containers, [*Boost.Intrusive] offers special cloning functions. See
|
||||
[link intrusive.clone_from Cloning [*Boost.Intrusive] containers] section for more information.
|
||||
[link boost_intrusive.clone_from Cloning [*Boost.Intrusive] containers] section for more information.
|
||||
|
||||
* Analyzing thread-safety of a program that uses containers is harder with intrusive containers, becuase
|
||||
the container might be modified indirectly without an explicitly call to a container member.
|
||||
@@ -214,18 +214,12 @@ Intrusive containers have also downsides:
|
||||
]
|
||||
|
||||
For a performance comparison between Intrusive and Non-intrusive containers see
|
||||
[link intrusive.performance Performance] section.
|
||||
[link boost_intrusive.performance Performance] section.
|
||||
|
||||
[endsect]
|
||||
|
||||
[endsect]
|
||||
|
||||
[/
|
||||
[section:quick_guide Quick guide for the impatient]
|
||||
|
||||
[endsect]
|
||||
]
|
||||
|
||||
[section:usage How to use Boost.Intrusive]
|
||||
|
||||
If you plan to use a class in an intrusive container, you have to make some decisions
|
||||
@@ -265,11 +259,11 @@ three template arguments:
|
||||
|
||||
* The second template argument controls the linking policy. [*Boost.Intrusive] currently supports
|
||||
3 policies: `normal_link`, `safe_link`, `auto_unlink`. More about these in the sections
|
||||
[link intrusive.safe_hook Safe hooks] and [link intrusive.auto_unlink_hooks Auto-unlink hooks]
|
||||
[link boost_intrusive.safe_hook Safe hooks] and [link boost_intrusive.auto_unlink_hooks Auto-unlink hooks]
|
||||
|
||||
* The third template argument is the pointer type to be used internally in the hook.
|
||||
The default value is `void *`, which means that raw pointers will be used in the hook.
|
||||
More about this in the section titled [link intrusive.using_smart_pointers Using smart pointers with Boost.Intrusive containers]
|
||||
More about this in the section titled [link boost_intrusive.using_smart_pointers Using smart pointers with Boost.Intrusive containers]
|
||||
|
||||
Example:
|
||||
|
||||
@@ -413,10 +407,10 @@ Even if the interface of [classref boost::intrusive::list list] is similar to
|
||||
you directly store objects in intrusive containers, not copies. The lifetime of a
|
||||
stored object is not bound to or managed by the container:
|
||||
|
||||
* When the container gets destroyed before the object, the object is not destroyed,
|
||||
* When the container gets disposed before the object, the object is not disposed,
|
||||
so you have to be careful to avoid resource leaks.
|
||||
|
||||
* When the object is destroyed before the container, your program is likely to crash,
|
||||
* When the object is disposed before the container, your program is likely to crash,
|
||||
because the container contains a pointer to an non-existing object.
|
||||
|
||||
[endsect]
|
||||
@@ -556,6 +550,8 @@ Apart from that, [*Boost.Intrusive] offers additional features:
|
||||
|
||||
[section:safe_hook Safe hooks]
|
||||
|
||||
[section:features Features of the safe mode]
|
||||
|
||||
[*Boost.Intrusive] hooks can be configured to operate in safe-link mode.
|
||||
The safe mode is activated by default:
|
||||
|
||||
@@ -585,12 +581,28 @@ If the object is not actually inserted
|
||||
in a container, the hook is the default state and if it's inserted in a container, the
|
||||
hook is not in the default state.
|
||||
|
||||
[*Note:] All assertions raised by [*Boost-Intrusive] hooks and containers, are
|
||||
implemented using `BOOST_ASSERT`, which can be configured by the user. See
|
||||
[@http://www.boost.org/libs/utility/assert.html] for more information about
|
||||
`BOOST_ASSERT`.
|
||||
[endsect]
|
||||
|
||||
(to-do example!!)
|
||||
[section:configuring Configuring safe-mode assertions]
|
||||
|
||||
By default, all safe-mode assertions raised by [*Boost-Intrusive] hooks
|
||||
and containers in are implemented using `BOOST_ASSERT`, which can be configured by
|
||||
the user. See [@http://www.boost.org/libs/utility/assert.html] for more
|
||||
information about `BOOST_ASSERT`.
|
||||
|
||||
`BOOST_ASSERT` is globally configured for all the libraries, so the user might
|
||||
want to redefine safe-mode assertions without modifying `BOOST_ASSERT`. This can
|
||||
be achieved redefining the following macros:
|
||||
|
||||
* `BOOST_INTRUSIVE_SAFE_MODE_CONTAINER_INSERTION_ASSERT`: This assertion will be
|
||||
used in insertion functions of the intrusive containers to check that
|
||||
the hook of the value to be inserted is default constructed.
|
||||
* `BOOST_INTRUSIVE_SAFE_MODE_HOOK_DESTRUCTOR_ASSERT`: This assertion will be
|
||||
used in hooks' destructors to check that the hook is in a default state.
|
||||
|
||||
If any of these macros is not redefined, it will be defaulted to `BOOST_ASSERT`.
|
||||
|
||||
[endsect]
|
||||
|
||||
[endsect]
|
||||
|
||||
@@ -608,7 +620,7 @@ implemented using `BOOST_ASSERT`, which can be configured by the user. See
|
||||
|
||||
These hooks have exactly the same size overhead as their analogue non auto-unlinking
|
||||
hooks, but they have a restriction: they can only be used with
|
||||
[link intrusive.presenting_containers non-constant time containers].
|
||||
[link boost_intrusive.presenting_containers non-constant time containers].
|
||||
There is a reason for this:
|
||||
|
||||
* Auto-unlink hooks don't store any reference to the container where they are inserted.
|
||||
@@ -989,7 +1001,7 @@ equality functor for those values:
|
||||
|
||||
Each hashed container needs [*its own bucket array]. Two hashed containers
|
||||
[*can't] share the same `bucket_type` elements. The bucket array [*must] be
|
||||
destroyed [*after] the container using it is destroyed, otherwise, the result
|
||||
disposed [*after] the container using it is disposed, otherwise, the result
|
||||
is undefined.
|
||||
|
||||
[section:unordered_set_unordered_multiset_performance unordered_set and unordered_multiset performance notes]
|
||||
@@ -1217,7 +1229,7 @@ For more information about advanced lookup and insertion functions see
|
||||
|
||||
[endsect]
|
||||
|
||||
[section:erasing_and_destroying Erasing and destroying values from Boost.Intrusive containers]
|
||||
[section:erasing_and_disposing Erasing and disposing values from Boost.Intrusive containers]
|
||||
|
||||
One of the most tedious tasks when using intrusive containers is the management of the erased elements.
|
||||
When using STL containers, the container itself unlinks and destroys the contained elements, but with
|
||||
@@ -1237,20 +1249,27 @@ object that will be called after the element has been erased from the container.
|
||||
|
||||
[c++]
|
||||
|
||||
template<class Pred, class Destroyer>
|
||||
void remove_and_destroy_if(Pred pred, Destroyer destroyer)
|
||||
template<class Pred, class Disposer>
|
||||
void remove_and_dispose_if(Pred pred, Disposer disposer)
|
||||
|
||||
This function can be used to efficiently remove and destroy elements. `remove_and_destroy_if`
|
||||
will call "destroyer" function object for every removed element. [classref boost::intrusive::list list] offers
|
||||
more functions taking a destroyer function object as argument, like `erase_and_destroy`, `clear_and_destroy`,
|
||||
`remove_and_destroy`... Let's see an small example:
|
||||
With this function the user can efficiently remove and destroy elements if the disposer
|
||||
function destroys an object: `remove_and_dispose_if`
|
||||
will call "disposer" function object for every removed element. [classref boost::intrusive::list list] offers
|
||||
more functions taking a disposer function object as argument, like `erase_and_dispose`, `clear_and_dispose`,
|
||||
`remove_and_dispose`...
|
||||
|
||||
[import ../example/doc_erasing_and_destroying.cpp]
|
||||
[doc_erasing_and_destroying]
|
||||
Note that the disposing function does not need to just destroy the object. It can
|
||||
implement any other operation like inserting the remove object in another container.
|
||||
Let's see an small example:
|
||||
|
||||
All [*Boost.Intrusive] containers offer these "erase + destroy" additional members for all functions
|
||||
[import ../example/doc_erasing_and_disposing.cpp]
|
||||
[doc_erasing_and_disposing]
|
||||
|
||||
All [*Boost.Intrusive] containers offer these "erase + dispose" additional members for all functions
|
||||
that erase an element from the container.
|
||||
|
||||
|
||||
|
||||
[endsect]
|
||||
|
||||
[section:clone_from Cloning [*Boost.Intrusive] containers]
|
||||
@@ -1269,8 +1288,8 @@ Apart from the container to be cloned, `clone_from` takes two function objects a
|
||||
|
||||
[c++]
|
||||
|
||||
template <class Cloner, class Destroyer>
|
||||
void clone_from(const list &src, Cloner cloner, Destroyer destroyer);
|
||||
template <class Cloner, class Disposer>
|
||||
void clone_from(const list &src, Cloner cloner, Disposer disposer);
|
||||
|
||||
This function will make `*this` a clone of `src`. Let's explain the arguments:
|
||||
|
||||
@@ -1278,14 +1297,14 @@ This function will make `*this` a clone of `src`. Let's explain the arguments:
|
||||
* The second parameter is a function object that will clone `value_type` objects and
|
||||
return a pointer to the clone. It must implement the following function:
|
||||
`pointer operator()(const value_type &)`.
|
||||
* The second parameter is a function object that will destroy `value_type` objects. It's used first
|
||||
to empty the container before cloning and to erase the elements if an exception is thrown.
|
||||
* The second parameter is a function object that will dispose `value_type` objects. It's used first
|
||||
to empty the container before cloning and to dispose the elements if an exception is thrown.
|
||||
|
||||
The cloning function works as follows:
|
||||
|
||||
* First clears and destroys all the elements from *this using the destroyer function object.
|
||||
* First clears and disposes all the elements from *this using the disposer function object.
|
||||
* After that starts cloning all the elements of the source container using the cloner function object.
|
||||
* If any operation in the cloning function (for example, the cloner function object) throws, all the constructed elements are destroyed using the destroyer function object.
|
||||
* If any operation in the cloning function (for example, the cloner function object) throws, all the constructed elements are disposed using the disposer function object.
|
||||
|
||||
|
||||
Here's an example of `clone_from`:
|
||||
@@ -1575,7 +1594,7 @@ before explaining the customization options of [*Boost.Intrusive].
|
||||
|
||||
[section:node_algorithms Node algorithms with custom NodeTraits]
|
||||
|
||||
As explained in the [link intrusive.concepts Concepts] section, [*Boost.Intrusive]
|
||||
As explained in the [link boost_intrusive.concepts Concepts] section, [*Boost.Intrusive]
|
||||
containers are implemented using node algorithms that work on generic nodes.
|
||||
|
||||
Sometimes, the use of intrusive containers is expensive for some environments
|
||||
@@ -1756,7 +1775,7 @@ For a complete rbtree of functions see
|
||||
|
||||
[section:value_traits Containers with custom ValueTraits]
|
||||
|
||||
As explained in the [link intrusive.concepts Concepts] section, [*Boost.Intrusive]
|
||||
As explained in the [link boost_intrusive.concepts Concepts] section, [*Boost.Intrusive]
|
||||
containers are templatized using a `ValueTraits` parameter. This parameter contains
|
||||
all the information to glue the `value_type` of the containers and the node to be
|
||||
used in node algorithms, since these types can be different. Apart from this,
|
||||
@@ -1800,7 +1819,7 @@ Let's explain each type and function:
|
||||
|
||||
* ['node_traits]: The node configuration that it's needed by node algorithms.
|
||||
These node traits and algorithms are
|
||||
described in the previous chapter: [link intrusive.node_algorithms Nodes Algorithms].
|
||||
described in the previous chapter: [link boost_intrusive.node_algorithms Nodes Algorithms].
|
||||
|
||||
* If my_value_traits is meant to be used with [classref boost::intrusive::slist slist],
|
||||
`node_traits` should follow
|
||||
@@ -2012,7 +2031,7 @@ to have more than one hook per user type opens the possibility to implement mult
|
||||
containers on top of [*Boost.Intrusive].
|
||||
|
||||
[*Boost.Intrusive] containers implement advanced functions taking function objects
|
||||
as arguments (`clone_from`, `erase_and_destroy`, `insert_check`...). These
|
||||
as arguments (`clone_from`, `erase_and_dispose`, `insert_check`...). These
|
||||
functions come handy when implementing non-intrusive containers
|
||||
(for example, STL-like containers) on top of intrusive containers.
|
||||
|
||||
@@ -2397,7 +2416,8 @@ all the objects to be inserted in intrusive containers in containers like `std::
|
||||
* Intel 9.1/WinXP
|
||||
* GCC 4.1.2/Linux
|
||||
* Codewarrior 9.4/WinXP
|
||||
* GCC 3.4.3 Solaris 11
|
||||
* GCC 3.4.3/Solaris 11
|
||||
* GCC 4.0/Mac Os 10.4.1
|
||||
|
||||
[endsect]
|
||||
|
||||
@@ -2428,7 +2448,7 @@ helpful discussions.
|
||||
|
||||
[endsect]
|
||||
|
||||
[xinclude intrusive_doxygen.boostbook]
|
||||
[xinclude intrusive_doxygen.xml]
|
||||
|
||||
[section:license_notices License notices]
|
||||
|
||||
|
@@ -1,4 +1,4 @@
|
||||
# Boost Intrusive Library Documentation test Jamfile
|
||||
# Boost Intrusive Library Example Jamfile
|
||||
|
||||
# (C) Copyright Ion Gazta<74>aga 2006-2007.
|
||||
# Use, modification and distribution are subject to the
|
||||
@@ -31,4 +31,4 @@ rule test_all
|
||||
return $(all_rules) ;
|
||||
}
|
||||
|
||||
test-suite intrusive_doc : [ test_all r ] ;
|
||||
test-suite intrusive_example : [ test_all r ] : <threading>multi ;
|
@@ -38,8 +38,8 @@ class new_cloner
|
||||
{ return new my_class(clone_this); }
|
||||
};
|
||||
|
||||
//The destroyer object function
|
||||
class delete_destroyer
|
||||
//The disposer object function
|
||||
class delete_disposer
|
||||
{
|
||||
public:
|
||||
void operator()(my_class *delete_this)
|
||||
@@ -61,7 +61,7 @@ int main()
|
||||
|
||||
//Now clone "list" using "new" and "delete" object functions
|
||||
my_class_list cloned_list;
|
||||
cloned_list.clone_from(list, new_cloner(), delete_destroyer());
|
||||
cloned_list.clone_from(list, new_cloner(), delete_disposer());
|
||||
|
||||
//Test that both are equal
|
||||
if(cloned_list != list){
|
||||
@@ -72,7 +72,7 @@ int main()
|
||||
}
|
||||
|
||||
//Don't forget to free the memory from the second list
|
||||
cloned_list.clear_and_destroy(delete_destroyer());
|
||||
cloned_list.clear_and_dispose(delete_disposer());
|
||||
return 0;
|
||||
}
|
||||
//]
|
||||
|
@@ -9,7 +9,7 @@
|
||||
// See http://www.boost.org/libs/intrusive for documentation.
|
||||
//
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//[doc_erasing_and_destroying
|
||||
//[doc_erasing_and_disposing
|
||||
#include <boost/intrusive/list.hpp>
|
||||
|
||||
//A class that can be inserted in an intrusive list
|
||||
@@ -36,8 +36,8 @@ class is_even
|
||||
{ return 0 == (c.int_ % 2); }
|
||||
};
|
||||
|
||||
//The destroyer object function
|
||||
class delete_destroyer
|
||||
//The disposer object function
|
||||
class delete_disposer
|
||||
{
|
||||
public:
|
||||
void operator()(my_class *delete_this)
|
||||
@@ -57,17 +57,17 @@ int main()
|
||||
list.push_back(*new my_class(i));
|
||||
}
|
||||
|
||||
//Now use remove_and_destroy_if to erase and delete the objects
|
||||
list.remove_and_destroy_if(is_even(), delete_destroyer());
|
||||
//Now use remove_and_dispose_if to erase and delete the objects
|
||||
list.remove_and_dispose_if(is_even(), delete_disposer());
|
||||
}
|
||||
catch(...){
|
||||
//If something throws, make sure that all the memory is freed
|
||||
list.clear_and_destroy(delete_destroyer());
|
||||
list.clear_and_dispose(delete_disposer());
|
||||
throw;
|
||||
}
|
||||
|
||||
//Destroy remaining elements
|
||||
list.erase_and_destroy(list.begin(), list.end(), delete_destroyer());
|
||||
//Dispose remaining elements
|
||||
list.erase_and_dispose(list.begin(), list.end(), delete_disposer());
|
||||
return 0;
|
||||
}
|
||||
//]
|
@@ -79,4 +79,5 @@ int main()
|
||||
algo::erase(&header, n);
|
||||
return 0;
|
||||
}
|
||||
|
||||
//]
|
||||
|
@@ -93,7 +93,7 @@ void test_intrusive_list_push_back()
|
||||
for(int i = 0; i < NumElements; ++i)
|
||||
l.push_back(objects[i]);
|
||||
//Elements are unlinked in ilist's destructor
|
||||
//Elements are destroyed in vector's destructor
|
||||
//Elements are disposed in vector's destructor
|
||||
//]
|
||||
}
|
||||
ptime tend = microsec_clock::universal_time();
|
||||
@@ -111,7 +111,7 @@ void test_std_list_push_back()
|
||||
stdlist l;
|
||||
for(int i = 0; i < NumElements; ++i)
|
||||
l.push_back(typename stdlist::value_type(i));
|
||||
//Elements unlinked and destroyed in stdlist's destructor
|
||||
//Elements unlinked and disposed in stdlist's destructor
|
||||
//]
|
||||
}
|
||||
ptime tend = microsec_clock::universal_time();
|
||||
@@ -132,8 +132,8 @@ void test_compact_std_ptrlist_push_back()
|
||||
stdptrlist l;
|
||||
for(int i = 0; i < NumElements; ++i)
|
||||
l.push_back(&objects[i]);
|
||||
//Pointers to elements unlinked and destroyed in stdptrlist's destructor
|
||||
//Elements destroyed in vector's destructor
|
||||
//Pointers to elements unlinked and disposed in stdptrlist's destructor
|
||||
//Elements disposed in vector's destructor
|
||||
//]
|
||||
}
|
||||
ptime tend = microsec_clock::universal_time();
|
||||
@@ -155,8 +155,8 @@ void test_disperse_std_ptrlist_push_back()
|
||||
objects.push_back(typename stdlist::value_type(i));
|
||||
l.push_back(&objects.back());
|
||||
}
|
||||
//Pointers to elements unlinked and destroyed in stdptrlist's destructor
|
||||
//Elements unlinked and destroyed in stdlist's destructor
|
||||
//Pointers to elements unlinked and disposed in stdptrlist's destructor
|
||||
//Elements unlinked and disposed in stdlist's destructor
|
||||
//]
|
||||
}
|
||||
ptime tend = microsec_clock::universal_time();
|
||||
|
@@ -159,6 +159,9 @@
|
||||
<Filter
|
||||
Name="detail"
|
||||
Filter="">
|
||||
<File
|
||||
RelativePath="..\..\..\..\..\boost\intrusive\detail\assert.hpp">
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\..\..\..\boost\intrusive\detail\config_begin.hpp">
|
||||
</File>
|
||||
@@ -174,6 +177,9 @@
|
||||
<File
|
||||
RelativePath="..\..\..\..\..\boost\intrusive\detail\list_node.hpp">
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\..\..\..\boost\intrusive\detail\mpl.hpp">
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\..\..\..\..\boost\intrusive\detail\parent_from_member.hpp">
|
||||
</File>
|
||||
|
@@ -1,135 +1,137 @@
|
||||
<?xml version="1.0" encoding="Windows-1252"?>
|
||||
<VisualStudioProject
|
||||
ProjectType="Visual C++"
|
||||
Version="7.10"
|
||||
Name="list"
|
||||
ProjectGUID="{977B61B4-9968-497C-9F0B-24A8145473B8}"
|
||||
RootNamespace="list"
|
||||
Keyword="Win32Proj">
|
||||
<Platforms>
|
||||
<Platform
|
||||
Name="Win32"/>
|
||||
</Platforms>
|
||||
<Configurations>
|
||||
<Configuration
|
||||
Name="Debug|Win32"
|
||||
OutputDirectory="Debug"
|
||||
IntermediateDirectory="Debug"
|
||||
ConfigurationType="1"
|
||||
CharacterSet="2">
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="0"
|
||||
AdditionalIncludeDirectories="../../../../../"
|
||||
PreprocessorDefinitions="BOOST_DATE_TIME_NO_LIB"
|
||||
MinimalRebuild="TRUE"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="5"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="3"
|
||||
Detect64BitPortabilityProblems="TRUE"
|
||||
DebugInformationFormat="4"/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
OutputFile="$(OutDir)/list.exe"
|
||||
LinkIncremental="2"
|
||||
GenerateDebugInformation="TRUE"
|
||||
ProgramDatabaseFile="$(OutDir)/list.pdb"
|
||||
SubSystem="1"
|
||||
TargetMachine="1"/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"/>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"/>
|
||||
<Tool
|
||||
Name="VCWebDeploymentTool"/>
|
||||
<Tool
|
||||
Name="VCManagedWrapperGeneratorTool"/>
|
||||
<Tool
|
||||
Name="VCAuxiliaryManagedWrapperGeneratorTool"/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Release|Win32"
|
||||
OutputDirectory="Release"
|
||||
IntermediateDirectory="Release"
|
||||
ConfigurationType="1"
|
||||
CharacterSet="2">
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
AdditionalIncludeDirectories="../../../../../"
|
||||
PreprocessorDefinitions="BOOST_DATE_TIME_NO_LIB"
|
||||
RuntimeLibrary="4"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="3"
|
||||
Detect64BitPortabilityProblems="TRUE"
|
||||
DebugInformationFormat="3"/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
OutputFile="$(OutDir)/list.exe"
|
||||
LinkIncremental="1"
|
||||
GenerateDebugInformation="TRUE"
|
||||
SubSystem="1"
|
||||
OptimizeReferences="2"
|
||||
EnableCOMDATFolding="2"
|
||||
TargetMachine="1"/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"/>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"/>
|
||||
<Tool
|
||||
Name="VCWebDeploymentTool"/>
|
||||
<Tool
|
||||
Name="VCManagedWrapperGeneratorTool"/>
|
||||
<Tool
|
||||
Name="VCAuxiliaryManagedWrapperGeneratorTool"/>
|
||||
</Configuration>
|
||||
</Configurations>
|
||||
<References>
|
||||
</References>
|
||||
<Files>
|
||||
<Filter
|
||||
Name="Source Files"
|
||||
Filter="cpp;c;cxx;def;odl;idl;hpj;bat;asm;asmx"
|
||||
UniqueIdentifier="{4FC737F1-C7A5-4376-A066-2A32D752A2FF}">
|
||||
<File
|
||||
RelativePath="..\..\..\test\list_test.cpp">
|
||||
</File>
|
||||
</Filter>
|
||||
<Filter
|
||||
Name="Header Files"
|
||||
Filter="h;hpp;hxx;hm;inl;inc;xsd"
|
||||
UniqueIdentifier="{93995380-89BD-4b04-88EB-625FBE52EBFB}">
|
||||
</Filter>
|
||||
<Filter
|
||||
Name="Resource Files"
|
||||
Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx"
|
||||
UniqueIdentifier="{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}">
|
||||
</Filter>
|
||||
</Files>
|
||||
<Globals>
|
||||
</Globals>
|
||||
ProjectType="Visual C++"
|
||||
Version="7.10"
|
||||
Name="list"
|
||||
ProjectGUID="{977B61B4-9968-497C-9F0B-24A8145473B8}"
|
||||
RootNamespace="list"
|
||||
Keyword="Win32Proj">
|
||||
<Platforms>
|
||||
<Platform
|
||||
Name="Win32"/>
|
||||
</Platforms>
|
||||
<Configurations>
|
||||
<Configuration
|
||||
Name="Debug|Win32"
|
||||
OutputDirectory="Debug"
|
||||
IntermediateDirectory="Debug"
|
||||
ConfigurationType="1"
|
||||
CharacterSet="2">
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="0"
|
||||
AdditionalIncludeDirectories="../../../../../"
|
||||
PreprocessorDefinitions="BOOST_DATE_TIME_NO_LIB"
|
||||
GeneratePreprocessedFile="0"
|
||||
KeepComments="FALSE"
|
||||
MinimalRebuild="TRUE"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="5"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="3"
|
||||
Detect64BitPortabilityProblems="TRUE"
|
||||
DebugInformationFormat="4"/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
OutputFile="$(OutDir)/list.exe"
|
||||
LinkIncremental="2"
|
||||
GenerateDebugInformation="TRUE"
|
||||
ProgramDatabaseFile="$(OutDir)/list.pdb"
|
||||
SubSystem="1"
|
||||
TargetMachine="1"/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"/>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"/>
|
||||
<Tool
|
||||
Name="VCWebDeploymentTool"/>
|
||||
<Tool
|
||||
Name="VCManagedWrapperGeneratorTool"/>
|
||||
<Tool
|
||||
Name="VCAuxiliaryManagedWrapperGeneratorTool"/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Release|Win32"
|
||||
OutputDirectory="Release"
|
||||
IntermediateDirectory="Release"
|
||||
ConfigurationType="1"
|
||||
CharacterSet="2">
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
AdditionalIncludeDirectories="../../../../../"
|
||||
PreprocessorDefinitions="BOOST_DATE_TIME_NO_LIB"
|
||||
RuntimeLibrary="4"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="3"
|
||||
Detect64BitPortabilityProblems="TRUE"
|
||||
DebugInformationFormat="3"/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
OutputFile="$(OutDir)/list.exe"
|
||||
LinkIncremental="1"
|
||||
GenerateDebugInformation="TRUE"
|
||||
SubSystem="1"
|
||||
OptimizeReferences="2"
|
||||
EnableCOMDATFolding="2"
|
||||
TargetMachine="1"/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"/>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"/>
|
||||
<Tool
|
||||
Name="VCWebDeploymentTool"/>
|
||||
<Tool
|
||||
Name="VCManagedWrapperGeneratorTool"/>
|
||||
<Tool
|
||||
Name="VCAuxiliaryManagedWrapperGeneratorTool"/>
|
||||
</Configuration>
|
||||
</Configurations>
|
||||
<References>
|
||||
</References>
|
||||
<Files>
|
||||
<Filter
|
||||
Name="Source Files"
|
||||
Filter="cpp;c;cxx;def;odl;idl;hpj;bat;asm;asmx"
|
||||
UniqueIdentifier="{4FC737F1-C7A5-4376-A066-2A32D752A2FF}">
|
||||
<File
|
||||
RelativePath="..\..\..\test\list_test.cpp">
|
||||
</File>
|
||||
</Filter>
|
||||
<Filter
|
||||
Name="Header Files"
|
||||
Filter="h;hpp;hxx;hm;inl;inc;xsd"
|
||||
UniqueIdentifier="{93995380-89BD-4b04-88EB-625FBE52EBFB}">
|
||||
</Filter>
|
||||
<Filter
|
||||
Name="Resource Files"
|
||||
Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx"
|
||||
UniqueIdentifier="{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}">
|
||||
</Filter>
|
||||
</Files>
|
||||
<Globals>
|
||||
</Globals>
|
||||
</VisualStudioProject>
|
||||
|
@@ -1,134 +1,135 @@
|
||||
<?xml version="1.0" encoding="Windows-1252"?>
|
||||
<VisualStudioProject
|
||||
ProjectType="Visual C++"
|
||||
Version="7.10"
|
||||
Name="unordered_multiset"
|
||||
ProjectGUID="{9101EE76-BB6C-2C91-F4B7-A9F3B9490279}"
|
||||
Keyword="Win32Proj">
|
||||
<Platforms>
|
||||
<Platform
|
||||
Name="Win32"/>
|
||||
</Platforms>
|
||||
<Configurations>
|
||||
<Configuration
|
||||
Name="Debug|Win32"
|
||||
OutputDirectory="Debug"
|
||||
IntermediateDirectory="Debug"
|
||||
ConfigurationType="1"
|
||||
CharacterSet="2">
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="0"
|
||||
AdditionalIncludeDirectories="../../../../../"
|
||||
PreprocessorDefinitions="WIN32;_DEBUG;_CONSOLE"
|
||||
MinimalRebuild="TRUE"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="5"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="3"
|
||||
Detect64BitPortabilityProblems="TRUE"
|
||||
DebugInformationFormat="4"/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
OutputFile="$(OutDir)/unordered_multiset.exe"
|
||||
LinkIncremental="2"
|
||||
GenerateDebugInformation="TRUE"
|
||||
ProgramDatabaseFile="$(OutDir)/unordered_multiset.pdb"
|
||||
SubSystem="1"
|
||||
TargetMachine="1"/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"/>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"/>
|
||||
<Tool
|
||||
Name="VCWebDeploymentTool"/>
|
||||
<Tool
|
||||
Name="VCManagedWrapperGeneratorTool"/>
|
||||
<Tool
|
||||
Name="VCAuxiliaryManagedWrapperGeneratorTool"/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Release|Win32"
|
||||
OutputDirectory="Release"
|
||||
IntermediateDirectory="Release"
|
||||
ConfigurationType="1"
|
||||
CharacterSet="2">
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
AdditionalIncludeDirectories="../../../../../"
|
||||
PreprocessorDefinitions="WIN32;NDEBUG;_CONSOLE"
|
||||
RuntimeLibrary="4"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="3"
|
||||
Detect64BitPortabilityProblems="TRUE"
|
||||
DebugInformationFormat="3"/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
OutputFile="$(OutDir)/unordered_multiset.exe"
|
||||
LinkIncremental="1"
|
||||
GenerateDebugInformation="TRUE"
|
||||
SubSystem="1"
|
||||
OptimizeReferences="2"
|
||||
EnableCOMDATFolding="2"
|
||||
TargetMachine="1"/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"/>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"/>
|
||||
<Tool
|
||||
Name="VCWebDeploymentTool"/>
|
||||
<Tool
|
||||
Name="VCManagedWrapperGeneratorTool"/>
|
||||
<Tool
|
||||
Name="VCAuxiliaryManagedWrapperGeneratorTool"/>
|
||||
</Configuration>
|
||||
</Configurations>
|
||||
<References>
|
||||
</References>
|
||||
<Files>
|
||||
<Filter
|
||||
Name="Source Files"
|
||||
Filter="cpp;c;cxx;def;odl;idl;hpj;bat;asm;asmx"
|
||||
UniqueIdentifier="{4F3C77F1-B78A-C745-4726-2D752AA322FF}">
|
||||
<File
|
||||
RelativePath="..\..\..\test\unordered_multiset_test.cpp">
|
||||
</File>
|
||||
</Filter>
|
||||
<Filter
|
||||
Name="Header Files"
|
||||
Filter="h;hpp;hxx;hm;inl;inc;xsd"
|
||||
UniqueIdentifier="{99954380-9C8D-084c-4b04-62E52E6FBBFB}">
|
||||
</Filter>
|
||||
<Filter
|
||||
Name="Resource Files"
|
||||
Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx"
|
||||
UniqueIdentifier="{6A181B76-FDA6800-8E8B-0A66-813A3BB1AD01}">
|
||||
</Filter>
|
||||
</Files>
|
||||
<Globals>
|
||||
</Globals>
|
||||
ProjectType="Visual C++"
|
||||
Version="7.10"
|
||||
Name="unordered_multiset"
|
||||
ProjectGUID="{9101EE76-BB6C-2C91-F4B7-A9F3B9490279}"
|
||||
Keyword="Win32Proj">
|
||||
<Platforms>
|
||||
<Platform
|
||||
Name="Win32"/>
|
||||
</Platforms>
|
||||
<Configurations>
|
||||
<Configuration
|
||||
Name="Debug|Win32"
|
||||
OutputDirectory="Debug"
|
||||
IntermediateDirectory="Debug"
|
||||
ConfigurationType="1"
|
||||
CharacterSet="2">
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
Optimization="0"
|
||||
AdditionalIncludeDirectories="../../../../../"
|
||||
PreprocessorDefinitions="WIN32;_DEBUG;_CONSOLE"
|
||||
GeneratePreprocessedFile="0"
|
||||
MinimalRebuild="TRUE"
|
||||
BasicRuntimeChecks="3"
|
||||
RuntimeLibrary="5"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="3"
|
||||
Detect64BitPortabilityProblems="TRUE"
|
||||
DebugInformationFormat="4"/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
OutputFile="$(OutDir)/unordered_multiset.exe"
|
||||
LinkIncremental="2"
|
||||
GenerateDebugInformation="TRUE"
|
||||
ProgramDatabaseFile="$(OutDir)/unordered_multiset.pdb"
|
||||
SubSystem="1"
|
||||
TargetMachine="1"/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"/>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"/>
|
||||
<Tool
|
||||
Name="VCWebDeploymentTool"/>
|
||||
<Tool
|
||||
Name="VCManagedWrapperGeneratorTool"/>
|
||||
<Tool
|
||||
Name="VCAuxiliaryManagedWrapperGeneratorTool"/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Release|Win32"
|
||||
OutputDirectory="Release"
|
||||
IntermediateDirectory="Release"
|
||||
ConfigurationType="1"
|
||||
CharacterSet="2">
|
||||
<Tool
|
||||
Name="VCCLCompilerTool"
|
||||
AdditionalIncludeDirectories="../../../../../"
|
||||
PreprocessorDefinitions="WIN32;NDEBUG;_CONSOLE"
|
||||
RuntimeLibrary="4"
|
||||
UsePrecompiledHeader="0"
|
||||
WarningLevel="3"
|
||||
Detect64BitPortabilityProblems="TRUE"
|
||||
DebugInformationFormat="3"/>
|
||||
<Tool
|
||||
Name="VCCustomBuildTool"/>
|
||||
<Tool
|
||||
Name="VCLinkerTool"
|
||||
OutputFile="$(OutDir)/unordered_multiset.exe"
|
||||
LinkIncremental="1"
|
||||
GenerateDebugInformation="TRUE"
|
||||
SubSystem="1"
|
||||
OptimizeReferences="2"
|
||||
EnableCOMDATFolding="2"
|
||||
TargetMachine="1"/>
|
||||
<Tool
|
||||
Name="VCMIDLTool"/>
|
||||
<Tool
|
||||
Name="VCPostBuildEventTool"/>
|
||||
<Tool
|
||||
Name="VCPreBuildEventTool"/>
|
||||
<Tool
|
||||
Name="VCPreLinkEventTool"/>
|
||||
<Tool
|
||||
Name="VCResourceCompilerTool"/>
|
||||
<Tool
|
||||
Name="VCWebServiceProxyGeneratorTool"/>
|
||||
<Tool
|
||||
Name="VCXMLDataGeneratorTool"/>
|
||||
<Tool
|
||||
Name="VCWebDeploymentTool"/>
|
||||
<Tool
|
||||
Name="VCManagedWrapperGeneratorTool"/>
|
||||
<Tool
|
||||
Name="VCAuxiliaryManagedWrapperGeneratorTool"/>
|
||||
</Configuration>
|
||||
</Configurations>
|
||||
<References>
|
||||
</References>
|
||||
<Files>
|
||||
<Filter
|
||||
Name="Source Files"
|
||||
Filter="cpp;c;cxx;def;odl;idl;hpj;bat;asm;asmx"
|
||||
UniqueIdentifier="{4F3C77F1-B78A-C745-4726-2D752AA322FF}">
|
||||
<File
|
||||
RelativePath="..\..\..\test\unordered_multiset_test.cpp">
|
||||
</File>
|
||||
</Filter>
|
||||
<Filter
|
||||
Name="Header Files"
|
||||
Filter="h;hpp;hxx;hm;inl;inc;xsd"
|
||||
UniqueIdentifier="{99954380-9C8D-084c-4b04-62E52E6FBBFB}">
|
||||
</Filter>
|
||||
<Filter
|
||||
Name="Resource Files"
|
||||
Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx"
|
||||
UniqueIdentifier="{6A181B76-FDA6800-8E8B-0A66-813A3BB1AD01}">
|
||||
</Filter>
|
||||
</Files>
|
||||
<Globals>
|
||||
</Globals>
|
||||
</VisualStudioProject>
|
||||
|
@@ -31,4 +31,4 @@ rule test_all
|
||||
return $(all_rules) ;
|
||||
}
|
||||
|
||||
test-suite intrusive_test : [ test_all r ] ;
|
||||
test-suite intrusive_test : [ test_all r ] : <threading>multi ;
|
||||
|
@@ -19,7 +19,7 @@ namespace boost {
|
||||
namespace intrusive {
|
||||
namespace test {
|
||||
|
||||
class delete_destroyer
|
||||
class delete_disposer
|
||||
{
|
||||
public:
|
||||
template <class Pointer>
|
||||
|
@@ -10,6 +10,8 @@
|
||||
// See http://www.boost.org/libs/intrusive for documentation.
|
||||
//
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#include <boost/intrusive/detail/config_begin.hpp>
|
||||
#include <boost/intrusive/list.hpp>
|
||||
#include <boost/intrusive/detail/pointer_to_other.hpp>
|
||||
#include "itestvalue.hpp"
|
||||
@@ -269,9 +271,9 @@ void test_list<ValueTraits>
|
||||
list_type testlist1 (&values[0], &values[0] + values.size());
|
||||
list_type testlist2;
|
||||
|
||||
testlist2.clone_from(testlist1, test::new_cloner(), test::delete_destroyer());
|
||||
testlist2.clone_from(testlist1, test::new_cloner(), test::delete_disposer());
|
||||
BOOST_TEST (testlist2 == testlist1);
|
||||
testlist2.clear_and_destroy(test::delete_destroyer());
|
||||
testlist2.clear_and_dispose(test::delete_disposer());
|
||||
BOOST_TEST (testlist2.empty());
|
||||
}
|
||||
|
||||
@@ -321,23 +323,23 @@ class test_main_template<VoidPointer, false>
|
||||
return 0;
|
||||
}
|
||||
};
|
||||
/*
|
||||
|
||||
//Explicit instantiations of non-counted classes
|
||||
template class boost::intrusive::list<list_base_raw, false>;
|
||||
template class boost::intrusive::list<list_member_raw, false>;
|
||||
template class boost::intrusive::list<list_auto_base_raw, false>;
|
||||
template class boost::intrusive::list<list_auto_member_raw, false>;
|
||||
template class boost::intrusive::list<list_base_smart, false>;
|
||||
template class boost::intrusive::list<list_member_smart, false>;
|
||||
template class boost::intrusive::list<list_auto_base_smart, false>;
|
||||
template class boost::intrusive::list<list_auto_member_smart, false>;
|
||||
//template class boost::intrusive::list<list_base_raw, false>;
|
||||
//template class boost::intrusive::list<list_member_raw, false>;
|
||||
//template class boost::intrusive::list<list_auto_base_raw, false>;
|
||||
//template class boost::intrusive::list<list_auto_member_raw, false>;
|
||||
//template class boost::intrusive::list<list_base_smart, false>;
|
||||
//template class boost::intrusive::list<list_member_smart, false>;
|
||||
//template class boost::intrusive::list<list_auto_base_smart, false>;
|
||||
//template class boost::intrusive::list<list_auto_member_smart, false>;
|
||||
|
||||
//Explicit instantiation of counted classes
|
||||
template class boost::intrusive::list<list_base_raw_t, true>;
|
||||
template class boost::intrusive::list<list_member_raw_t, true>;
|
||||
template class boost::intrusive::list<list_base_smart_t, true>;
|
||||
template class boost::intrusive::list<list_member_smart_t, true>;
|
||||
*/
|
||||
//template class boost::intrusive::list<list_base_raw_t, true>;
|
||||
//template class boost::intrusive::list<list_member_raw_t, true>;
|
||||
//template class boost::intrusive::list<list_base_smart_t, true>;
|
||||
//template class boost::intrusive::list<list_member_smart_t, true>;
|
||||
|
||||
int main( int, char* [] )
|
||||
{
|
||||
test_main_template<void*, false>()();
|
||||
@@ -346,3 +348,4 @@ int main( int, char* [] )
|
||||
test_main_template<boost::intrusive::smart_ptr<void>, true>()();
|
||||
return boost::report_errors();
|
||||
}
|
||||
#include <boost/intrusive/detail/config_end.hpp>
|
||||
|
@@ -10,7 +10,7 @@
|
||||
// See http://www.boost.org/libs/intrusive for documentation.
|
||||
//
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#include <boost/intrusive/detail/config_begin.hpp>
|
||||
#include <boost/intrusive/set.hpp>
|
||||
#include <boost/intrusive/detail/pointer_to_other.hpp>
|
||||
#include "itestvalue.hpp"
|
||||
@@ -201,9 +201,9 @@ void test_multiset<ValueTraits>
|
||||
multiset_type testmultiset1 (&values[0], &values[0] + values.size());
|
||||
multiset_type testmultiset2;
|
||||
|
||||
testmultiset2.clone_from(testmultiset1, test::new_cloner(), test::delete_destroyer());
|
||||
testmultiset2.clone_from(testmultiset1, test::new_cloner(), test::delete_disposer());
|
||||
BOOST_TEST (testmultiset2 == testmultiset1);
|
||||
testmultiset2.clear_and_destroy(test::delete_destroyer());
|
||||
testmultiset2.clear_and_dispose(test::delete_disposer());
|
||||
BOOST_TEST (testmultiset2.empty());
|
||||
}
|
||||
|
||||
@@ -293,4 +293,4 @@ int main( int, char* [] )
|
||||
return boost::report_errors();
|
||||
}
|
||||
|
||||
|
||||
#include <boost/intrusive/detail/config_end.hpp>
|
||||
|
@@ -10,7 +10,7 @@
|
||||
// See http://www.boost.org/libs/intrusive for documentation.
|
||||
//
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#include <boost/intrusive/detail/config_begin.hpp>
|
||||
#include <boost/intrusive/set.hpp>
|
||||
#include <boost/intrusive/detail/pointer_to_other.hpp>
|
||||
#include "itestvalue.hpp"
|
||||
@@ -204,9 +204,9 @@ void test_set<ValueTraits>
|
||||
set_type testset1 (&values[0], &values[0] + values.size());
|
||||
set_type testset2;
|
||||
|
||||
testset2.clone_from(testset1, test::new_cloner(), test::delete_destroyer());
|
||||
testset2.clone_from(testset1, test::new_cloner(), test::delete_disposer());
|
||||
BOOST_TEST (testset2 == testset1);
|
||||
testset2.clear_and_destroy(test::delete_destroyer());
|
||||
testset2.clear_and_dispose(test::delete_disposer());
|
||||
BOOST_TEST (testset2.empty());
|
||||
}
|
||||
|
||||
@@ -295,3 +295,4 @@ int main( int, char* [] )
|
||||
test_main_template<boost::intrusive::smart_ptr<void>, true>()();
|
||||
return boost::report_errors();
|
||||
}
|
||||
#include <boost/intrusive/detail/config_end.hpp>
|
||||
|
@@ -10,6 +10,7 @@
|
||||
// See http://www.boost.org/libs/intrusive for documentation.
|
||||
//
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
#include <boost/intrusive/detail/config_begin.hpp>
|
||||
#include <boost/intrusive/slist.hpp>
|
||||
#include <boost/intrusive/detail/pointer_to_other.hpp>
|
||||
#include "itestvalue.hpp"
|
||||
@@ -302,9 +303,9 @@ void test_slist<ValueTraits>
|
||||
list_type testlist1 (&values[0], &values[0] + values.size());
|
||||
list_type testlist2;
|
||||
|
||||
testlist2.clone_from(testlist1, test::new_cloner(), test::delete_destroyer());
|
||||
testlist2.clone_from(testlist1, test::new_cloner(), test::delete_disposer());
|
||||
BOOST_TEST (testlist2 == testlist1);
|
||||
testlist2.clear_and_destroy(test::delete_destroyer());
|
||||
testlist2.clear_and_dispose(test::delete_disposer());
|
||||
BOOST_TEST (testlist2.empty());
|
||||
}
|
||||
|
||||
@@ -379,3 +380,4 @@ int main(int, char* [])
|
||||
test_main_template<boost::intrusive::smart_ptr<void>, true>()();
|
||||
return boost::report_errors();
|
||||
}
|
||||
#include <boost/intrusive/detail/config_end.hpp>
|
||||
|
@@ -38,7 +38,7 @@ Semantics of an expression is defined only where it differs from, or is not defi
|
||||
Move constructor X(a) X().size() == a.size(). X() contains a copy of each of a's elements.
|
||||
Move constructor X b(a); b.size() == a.size(). b contains a copy of each of a's elements.
|
||||
Move Assignment operator b = a b.size() == a.size(). b contains a copy of each of a's elements.
|
||||
Destructor a.~X() Each of a's elements is destroyed, and memory allocated for them (if any) is deallocated.
|
||||
Destructor a.~X() Each of a's elements is disposed, and memory allocated for them (if any) is deallocated.
|
||||
Beginning of range a.begin() Returns an iterator pointing to the first element in the container. [7] a.begin() is either dereferenceable or past-the-end. It is past-the-end if and only if a.size() == 0.
|
||||
End of range a.end() Returns an iterator pointing one past the last element in the container. a.end() is past-the-end.
|
||||
Size a.size() Returns the size of the container, that is, its number of elements. [8] a.size() >= 0 && a.size() <= max_size()
|
||||
|
@@ -11,6 +11,7 @@
|
||||
//
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#include <boost/intrusive/detail/config_begin.hpp>
|
||||
#include <boost/intrusive/unordered_set.hpp>
|
||||
#include <boost/intrusive/detail/pointer_to_other.hpp>
|
||||
#include "itestvalue.hpp"
|
||||
@@ -281,14 +282,14 @@ void test_unordered_multiset<ValueTraits>
|
||||
unordered_multiset_type testset1 (buckets1, BucketSize, values.begin(), values.end());
|
||||
unordered_multiset_type testset2 (buckets2, BucketSize);
|
||||
|
||||
testset2.clone_from(testset1, test::new_cloner(), test::delete_destroyer());
|
||||
testset2.clone_from(testset1, test::new_cloner(), test::delete_disposer());
|
||||
//Ordering is not guarantee in the cloning so insert data in a set and test
|
||||
std::multiset<typename ValueTraits::value_type>
|
||||
src(testset1.begin(), testset1.end());
|
||||
std::multiset<typename ValueTraits::value_type>
|
||||
dst(testset2.begin(), testset2.end());
|
||||
BOOST_TEST (src == dst);
|
||||
testset2.clear_and_destroy(test::delete_destroyer());
|
||||
testset2.clear_and_dispose(test::delete_disposer());
|
||||
BOOST_TEST (testset2.empty());
|
||||
}
|
||||
{
|
||||
@@ -298,14 +299,14 @@ void test_unordered_multiset<ValueTraits>
|
||||
unordered_multiset_type testset1 (buckets1, BucketSize*2, values.begin(), values.end());
|
||||
unordered_multiset_type testset2 (buckets2, BucketSize);
|
||||
|
||||
testset2.clone_from(testset1, test::new_cloner(), test::delete_destroyer());
|
||||
testset2.clone_from(testset1, test::new_cloner(), test::delete_disposer());
|
||||
//Ordering is not guarantee in the cloning so insert data in a set and test
|
||||
std::multiset<typename ValueTraits::value_type>
|
||||
src(testset1.begin(), testset1.end());
|
||||
std::multiset<typename ValueTraits::value_type>
|
||||
dst(testset2.begin(), testset2.end());
|
||||
BOOST_TEST (src == dst);
|
||||
testset2.clear_and_destroy(test::delete_destroyer());
|
||||
testset2.clear_and_dispose(test::delete_disposer());
|
||||
BOOST_TEST (testset2.empty());
|
||||
}
|
||||
{
|
||||
@@ -315,14 +316,14 @@ void test_unordered_multiset<ValueTraits>
|
||||
unordered_multiset_type testset1 (buckets1, BucketSize, values.begin(), values.end());
|
||||
unordered_multiset_type testset2 (buckets2, BucketSize*2);
|
||||
|
||||
testset2.clone_from(testset1, test::new_cloner(), test::delete_destroyer());
|
||||
testset2.clone_from(testset1, test::new_cloner(), test::delete_disposer());
|
||||
//Ordering is not guarantee in the cloning so insert data in a set and test
|
||||
std::multiset<typename ValueTraits::value_type>
|
||||
src(testset1.begin(), testset1.end());
|
||||
std::multiset<typename ValueTraits::value_type>
|
||||
dst(testset2.begin(), testset2.end());
|
||||
BOOST_TEST (src == dst);
|
||||
testset2.clear_and_destroy(test::delete_destroyer());
|
||||
testset2.clear_and_dispose(test::delete_disposer());
|
||||
BOOST_TEST (testset2.empty());
|
||||
}
|
||||
}
|
||||
@@ -375,6 +376,7 @@ class test_main_template<VoidPointer, false>
|
||||
return 0;
|
||||
}
|
||||
};
|
||||
|
||||
/*
|
||||
//Explicit instantiations of non-counted classes
|
||||
template class boost::intrusive::unordered_multiset
|
||||
@@ -428,6 +430,7 @@ template class boost::intrusive::unordered_multiset
|
||||
, boost::hash<unordered_set_member_smart_t::value_type>
|
||||
, std::equal_to<unordered_set_member_smart_t::value_type>, true>;
|
||||
*/
|
||||
|
||||
int main( int, char* [] )
|
||||
{
|
||||
test_main_template<void*, false>()();
|
||||
@@ -436,3 +439,5 @@ int main( int, char* [] )
|
||||
test_main_template<boost::intrusive::smart_ptr<void>, true>()();
|
||||
return boost::report_errors();
|
||||
}
|
||||
|
||||
#include <boost/intrusive/detail/config_end.hpp>
|
||||
|
@@ -10,7 +10,7 @@
|
||||
// See http://www.boost.org/libs/intrusive for documentation.
|
||||
//
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#include <boost/intrusive/detail/config_begin.hpp>
|
||||
#include <boost/intrusive/unordered_set.hpp>
|
||||
#include <boost/intrusive/detail/pointer_to_other.hpp>
|
||||
#include "itestvalue.hpp"
|
||||
@@ -257,14 +257,14 @@ void test_unordered_set<ValueTraits>
|
||||
unordered_set_type testset1 (buckets1, BucketSize, values.begin(), values.end());
|
||||
unordered_set_type testset2 (buckets2, BucketSize);
|
||||
|
||||
testset2.clone_from(testset1, test::new_cloner(), test::delete_destroyer());
|
||||
testset2.clone_from(testset1, test::new_cloner(), test::delete_disposer());
|
||||
//Ordering is not guarantee in the cloning so insert data in a set and test
|
||||
std::set<typename ValueTraits::value_type>
|
||||
src(testset1.begin(), testset1.end());
|
||||
std::set<typename ValueTraits::value_type>
|
||||
dst(testset2.begin(), testset2.end());
|
||||
BOOST_TEST (src == dst );
|
||||
testset2.clear_and_destroy(test::delete_destroyer());
|
||||
testset2.clear_and_dispose(test::delete_disposer());
|
||||
BOOST_TEST (testset2.empty());
|
||||
}
|
||||
{
|
||||
@@ -274,14 +274,14 @@ void test_unordered_set<ValueTraits>
|
||||
unordered_set_type testset1 (buckets1, BucketSize*2, values.begin(), values.end());
|
||||
unordered_set_type testset2 (buckets2, BucketSize);
|
||||
|
||||
testset2.clone_from(testset1, test::new_cloner(), test::delete_destroyer());
|
||||
testset2.clone_from(testset1, test::new_cloner(), test::delete_disposer());
|
||||
//Ordering is not guarantee in the cloning so insert data in a set and test
|
||||
std::set<typename ValueTraits::value_type>
|
||||
src(testset1.begin(), testset1.end());
|
||||
std::set<typename ValueTraits::value_type>
|
||||
dst(testset2.begin(), testset2.end());
|
||||
BOOST_TEST (src == dst );
|
||||
testset2.clear_and_destroy(test::delete_destroyer());
|
||||
testset2.clear_and_dispose(test::delete_disposer());
|
||||
BOOST_TEST (testset2.empty());
|
||||
}
|
||||
{
|
||||
@@ -291,14 +291,14 @@ void test_unordered_set<ValueTraits>
|
||||
unordered_set_type testset1 (buckets1, BucketSize, values.begin(), values.end());
|
||||
unordered_set_type testset2 (buckets2, BucketSize*2);
|
||||
|
||||
testset2.clone_from(testset1, test::new_cloner(), test::delete_destroyer());
|
||||
testset2.clone_from(testset1, test::new_cloner(), test::delete_disposer());
|
||||
//Ordering is not guarantee in the cloning so insert data in a set and test
|
||||
std::set<typename ValueTraits::value_type>
|
||||
src(testset1.begin(), testset1.end());
|
||||
std::set<typename ValueTraits::value_type>
|
||||
dst(testset2.begin(), testset2.end());
|
||||
BOOST_TEST (src == dst );
|
||||
testset2.clear_and_destroy(test::delete_destroyer());
|
||||
testset2.clear_and_dispose(test::delete_disposer());
|
||||
BOOST_TEST (testset2.empty());
|
||||
}
|
||||
}
|
||||
@@ -411,3 +411,4 @@ int main( int, char* [] )
|
||||
test_main_template<boost::intrusive::smart_ptr<void>, true>()();
|
||||
return boost::report_errors();
|
||||
}
|
||||
#include <boost/intrusive/detail/config_end.hpp>
|
||||
|
Reference in New Issue
Block a user