Docs regen after adding notes about mixing objects compiled with different RTTI flags.

This commit is contained in:
Antony Polukhin
2013-10-22 17:02:29 +04:00
parent b5d27a8174
commit 4cebe4ff9d
14 changed files with 189 additions and 79 deletions

View File

@@ -34,7 +34,7 @@
</span>
<span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">typename</span> T<span class="special">&gt;</span> <a class="link" href="template_index.html" title="Class template_index">template_index</a> <span class="identifier">template_id</span><span class="special">(</span><span class="special">)</span><span class="special">;</span></pre></div>
<div class="refsect1">
<a name="idp34726784"></a><h2>Description</h2>
<a name="idp62085088"></a><h2>Description</h2>
<p>Method for constructing <code class="computeroutput"><a class="link" href="template_index.html" title="Class template_index">template_index</a></code> instance for type T. Strips const, volatile and &amp; modifiers from T. </p>
</div>
</div>

View File

@@ -34,7 +34,7 @@
</span>
<span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">typename</span> T<span class="special">&gt;</span> <a class="link" href="template_index.html" title="Class template_index">template_index</a> <span class="identifier">template_id_with_cvr</span><span class="special">(</span><span class="special">)</span><span class="special">;</span></pre></div>
<div class="refsect1">
<a name="idp34736640"></a><h2>Description</h2>
<a name="idp62094944"></a><h2>Description</h2>
<p>Factory method for constructing <code class="computeroutput"><a class="link" href="template_index.html" title="Class template_index">template_index</a></code> instance for type T. Does not strip const, volatile and &amp; modifiers from T. If T has no const, volatile, &amp; and &amp;&amp; modifiers, then returns exactly the same result as in case of calling `template_id&lt;T&gt;()`. </p>
</div>
</div>

View File

@@ -35,59 +35,59 @@
<span class="keyword">class</span> <a class="link" href="template_index.html" title="Class template_index">template_index</a> <span class="special">{</span>
<span class="keyword">public</span><span class="special">:</span>
<span class="comment">// <a class="link" href="template_index.html#boost.template_indexconstruct-copy-destruct">construct/copy/destruct</a></span>
<a class="link" href="template_index.html#idm25088-bb"><span class="identifier">template_index</span></a><span class="special">(</span><span class="special">)</span><span class="special">;</span>
<a class="link" href="template_index.html#idm31776-bb"><span class="identifier">template_index</span></a><span class="special">(</span><span class="special">)</span> <span class="keyword">noexcept</span><span class="special">;</span>
<span class="comment">// <a class="link" href="template_index.html#idm31920-bb">public member functions</a></span>
<span class="keyword">bool</span> <a class="link" href="template_index.html#idm31520-bb"><span class="identifier">before</span></a><span class="special">(</span><span class="keyword">const</span> <a class="link" href="template_index.html" title="Class template_index">template_index</a> <span class="special">&amp;</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span>
<span class="keyword">const</span> <span class="keyword">char</span> <span class="special">*</span> <a class="link" href="template_index.html#idm28896-bb"><span class="identifier">name</span></a><span class="special">(</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span>
<span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span> <a class="link" href="template_index.html#idm27648-bb"><span class="identifier">name_demangled</span></a><span class="special">(</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span>
<span class="identifier">std</span><span class="special">::</span><span class="identifier">size_t</span> <a class="link" href="template_index.html#idm26432-bb"><span class="identifier">hash_code</span></a><span class="special">(</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span>
<span class="comment">// <a class="link" href="template_index.html#idm6688-bb">public member functions</a></span>
<span class="keyword">bool</span> <a class="link" href="template_index.html#idm6128-bb"><span class="identifier">before</span></a><span class="special">(</span><span class="keyword">const</span> <a class="link" href="template_index.html" title="Class template_index">template_index</a> <span class="special">&amp;</span><span class="special">)</span> <span class="keyword">const</span> <span class="keyword">noexcept</span><span class="special">;</span>
<span class="keyword">const</span> <span class="keyword">char</span> <span class="special">*</span> <a class="link" href="template_index.html#idm3344-bb"><span class="identifier">name</span></a><span class="special">(</span><span class="special">)</span> <span class="keyword">const</span> <span class="keyword">noexcept</span><span class="special">;</span>
<span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span> <a class="link" href="template_index.html#idm1936-bb"><span class="identifier">name_demangled</span></a><span class="special">(</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span>
<span class="identifier">std</span><span class="special">::</span><span class="identifier">size_t</span> <a class="link" href="template_index.html#idm33488-bb"><span class="identifier">hash_code</span></a><span class="special">(</span><span class="special">)</span> <span class="keyword">const</span> <span class="keyword">noexcept</span><span class="special">;</span>
<span class="comment">// <a class="link" href="template_index.html#idm24544-bb">public static functions</a></span>
<span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">typename</span> T<span class="special">&gt;</span> <span class="keyword">static</span> <a class="link" href="template_index.html" title="Class template_index">template_index</a> <a class="link" href="template_index.html#idm24144-bb"><span class="identifier">construct</span></a><span class="special">(</span><span class="special">)</span><span class="special">;</span>
<span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">typename</span> T<span class="special">&gt;</span> <span class="keyword">static</span> <a class="link" href="template_index.html" title="Class template_index">template_index</a> <a class="link" href="template_index.html#idm20928-bb"><span class="identifier">construct_with_cvr</span></a><span class="special">(</span><span class="special">)</span><span class="special">;</span>
<span class="comment">// <a class="link" href="template_index.html#idm30800-bb">public static functions</a></span>
<span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">typename</span> T<span class="special">&gt;</span> <span class="keyword">static</span> <a class="link" href="template_index.html" title="Class template_index">template_index</a> <a class="link" href="template_index.html#idm30240-bb"><span class="identifier">construct</span></a><span class="special">(</span><span class="special">)</span><span class="special">;</span>
<span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">typename</span> T<span class="special">&gt;</span> <span class="keyword">static</span> <a class="link" href="template_index.html" title="Class template_index">template_index</a> <a class="link" href="template_index.html#idm27024-bb"><span class="identifier">construct_with_cvr</span></a><span class="special">(</span><span class="special">)</span><span class="special">;</span>
<span class="special">}</span><span class="special">;</span></pre></div>
<div class="refsect1">
<a name="idp34668480"></a><h2>Description</h2>
<a name="idp62024288"></a><h2>Description</h2>
<p>Copyable type_info that does not require RTTI and could store const, volatile and references if constructed via construct_with_cvr() </p>
<div class="refsect2">
<a name="idp34669264"></a><h3>
<a name="idp62025072"></a><h3>
<a name="boost.template_indexconstruct-copy-destruct"></a><code class="computeroutput">template_index</code>
public
construct/copy/destruct</h3>
<div class="orderedlist"><ol class="orderedlist" type="1"><li class="listitem">
<pre class="literallayout"><a name="idm25088-bb"></a><span class="identifier">template_index</span><span class="special">(</span><span class="special">)</span><span class="special">;</span></pre>
<pre class="literallayout"><a name="idm31776-bb"></a><span class="identifier">template_index</span><span class="special">(</span><span class="special">)</span> <span class="keyword">noexcept</span><span class="special">;</span></pre>
<p>Default constructor. </p>
</li></ol></div>
</div>
<div class="refsect2">
<a name="idp34674944"></a><h3>
<a name="idm31920-bb"></a><code class="computeroutput">template_index</code> public member functions</h3>
<a name="idp62031376"></a><h3>
<a name="idm6688-bb"></a><code class="computeroutput">template_index</code> public member functions</h3>
<div class="orderedlist"><ol class="orderedlist" type="1">
<li class="listitem">
<pre class="literallayout"><span class="keyword">bool</span> <a name="idm31520-bb"></a><span class="identifier">before</span><span class="special">(</span><span class="keyword">const</span> <a class="link" href="template_index.html" title="Class template_index">template_index</a> <span class="special">&amp;</span> rhs<span class="special">)</span> <span class="keyword">const</span><span class="special">;</span></pre>
<pre class="literallayout"><span class="keyword">bool</span> <a name="idm6128-bb"></a><span class="identifier">before</span><span class="special">(</span><span class="keyword">const</span> <a class="link" href="template_index.html" title="Class template_index">template_index</a> <span class="special">&amp;</span> rhs<span class="special">)</span> <span class="keyword">const</span> <span class="keyword">noexcept</span><span class="special">;</span></pre>
<p>Returns true if the type precedes the type of rhs in the collation order. The collation order is just an internal order. </p>
</li>
<li class="listitem">
<pre class="literallayout"><span class="keyword">const</span> <span class="keyword">char</span> <span class="special">*</span> <a name="idm28896-bb"></a><span class="identifier">name</span><span class="special">(</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span></pre>Returns raw name. </li>
<pre class="literallayout"><span class="keyword">const</span> <span class="keyword">char</span> <span class="special">*</span> <a name="idm3344-bb"></a><span class="identifier">name</span><span class="special">(</span><span class="special">)</span> <span class="keyword">const</span> <span class="keyword">noexcept</span><span class="special">;</span></pre>Returns raw name. </li>
<li class="listitem">
<pre class="literallayout"><span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span> <a name="idm27648-bb"></a><span class="identifier">name_demangled</span><span class="special">(</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span></pre>Returns user-friendly name. </li>
<pre class="literallayout"><span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span> <a name="idm1936-bb"></a><span class="identifier">name_demangled</span><span class="special">(</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span></pre>Returns user-friendly name. </li>
<li class="listitem">
<pre class="literallayout"><span class="identifier">std</span><span class="special">::</span><span class="identifier">size_t</span> <a name="idm26432-bb"></a><span class="identifier">hash_code</span><span class="special">(</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span></pre>
<pre class="literallayout"><span class="identifier">std</span><span class="special">::</span><span class="identifier">size_t</span> <a name="idm33488-bb"></a><span class="identifier">hash_code</span><span class="special">(</span><span class="special">)</span> <span class="keyword">const</span> <span class="keyword">noexcept</span><span class="special">;</span></pre>
<p>Function for getting hash value </p>
</li>
</ol></div>
</div>
<div class="refsect2">
<a name="idp34700672"></a><h3>
<a name="idm24544-bb"></a><code class="computeroutput">template_index</code> public static functions</h3>
<a name="idp62058976"></a><h3>
<a name="idm30800-bb"></a><code class="computeroutput">template_index</code> public static functions</h3>
<div class="orderedlist"><ol class="orderedlist" type="1">
<li class="listitem">
<pre class="literallayout"><span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">typename</span> T<span class="special">&gt;</span> <span class="keyword">static</span> <a class="link" href="template_index.html" title="Class template_index">template_index</a> <a name="idm24144-bb"></a><span class="identifier">construct</span><span class="special">(</span><span class="special">)</span><span class="special">;</span></pre>
<pre class="literallayout"><span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">typename</span> T<span class="special">&gt;</span> <span class="keyword">static</span> <a class="link" href="template_index.html" title="Class template_index">template_index</a> <a name="idm30240-bb"></a><span class="identifier">construct</span><span class="special">(</span><span class="special">)</span><span class="special">;</span></pre>
<p>Factory method for constructing <code class="computeroutput"><a class="link" href="template_index.html" title="Class template_index">template_index</a></code> instance for type T. Strips const, volatile and &amp; modifiers from T </p>
</li>
<li class="listitem">
<pre class="literallayout"><span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">typename</span> T<span class="special">&gt;</span> <span class="keyword">static</span> <a class="link" href="template_index.html" title="Class template_index">template_index</a> <a name="idm20928-bb"></a><span class="identifier">construct_with_cvr</span><span class="special">(</span><span class="special">)</span><span class="special">;</span></pre>
<pre class="literallayout"><span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">typename</span> T<span class="special">&gt;</span> <span class="keyword">static</span> <a class="link" href="template_index.html" title="Class template_index">template_index</a> <a name="idm27024-bb"></a><span class="identifier">construct_with_cvr</span><span class="special">(</span><span class="special">)</span><span class="special">;</span></pre>
<p>Factory method for constructing <code class="computeroutput"><a class="link" href="template_index.html" title="Class template_index">template_index</a></code> instance for type T. Does not strip const, volatile and &amp; modifiers from T </p>
</li>
</ol></div>

View File

@@ -34,7 +34,7 @@
</span>
<span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">typename</span> T<span class="special">&gt;</span> <a class="link" href="type_index.html" title="Class type_index">type_index</a> <span class="identifier">type_id</span><span class="special">(</span><span class="special">)</span><span class="special">;</span></pre></div>
<div class="refsect1">
<a name="idp34919952"></a><h2>Description</h2>
<a name="idp62287376"></a><h2>Description</h2>
<p>Function, to get <code class="computeroutput"><a class="link" href="type_index.html" title="Class type_index">type_index</a></code> for a type T. Strips const, volatile and &amp; modifiers from T. </p>
</div>
</div>

View File

@@ -7,7 +7,7 @@
<link rel="home" href="../index.html" title="Chapter&#160;1.&#160;Boost.TypeIndex 1.0">
<link rel="up" href="../boost_typeindex_header_reference.html#header.boost.type_index.type_index_impl_hpp" title="Header &lt;boost/type_index/type_index_impl.hpp&gt;">
<link rel="prev" href="type_id_with_cvr.html" title="Function template type_id_with_cvr">
<link rel="next" href="type_id_rtti_on_idp5763792.html" title="Function template type_id_rtti_only">
<link rel="next" href="type_id_rtti_on_idp5434192.html" title="Function template type_id_rtti_only">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -20,10 +20,10 @@
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="type_id_with_cvr.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../boost_typeindex_header_reference.html#header.boost.type_index.type_index_impl_hpp"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../index.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="type_id_rtti_on_idp5763792.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/next.png" alt="Next"></a>
<a accesskey="p" href="type_id_with_cvr.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../boost_typeindex_header_reference.html#header.boost.type_index.type_index_impl_hpp"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../index.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="type_id_rtti_on_idp5434192.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/next.png" alt="Next"></a>
</div>
<div class="refentry">
<a name="boost.type_id_rtti_on_idp5760464"></a><div class="titlepage"></div>
<a name="boost.type_id_rtti_on_idp5430736"></a><div class="titlepage"></div>
<div class="refnamediv">
<h2><span class="refentrytitle">Function template type_id_rtti_only</span></h2>
<p>boost::type_id_rtti_only</p>
@@ -34,7 +34,7 @@
</span>
<span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">typename</span> T<span class="special">&gt;</span> <a class="link" href="type_index.html" title="Class type_index">type_index</a> <span class="identifier">type_id_rtti_only</span><span class="special">(</span><span class="identifier">T</span> <span class="special">&amp;</span> rtti_val<span class="special">)</span><span class="special">;</span></pre></div>
<div class="refsect1">
<a name="idp34941040"></a><h2>Description</h2>
<a name="idp62308464"></a><h2>Description</h2>
<p>Function, that works exactly like C++ typeid(rtti_val) call, but returns <code class="computeroutput"><a class="link" href="type_index.html" title="Class type_index">boost::type_index</a></code>. This method available only with RTTI enabled. Without RTTI support it won't compile, producing a compile-time error with message: "boost::type_id_rtti_only(T&amp;) requires RTTI" </p>
</div>
</div>
@@ -48,7 +48,7 @@
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="type_id_with_cvr.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../boost_typeindex_header_reference.html#header.boost.type_index.type_index_impl_hpp"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../index.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="type_id_rtti_on_idp5763792.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/next.png" alt="Next"></a>
<a accesskey="p" href="type_id_with_cvr.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../boost_typeindex_header_reference.html#header.boost.type_index.type_index_impl_hpp"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../index.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="type_id_rtti_on_idp5434192.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -6,7 +6,7 @@
<meta name="generator" content="DocBook XSL Stylesheets V1.75.2">
<link rel="home" href="../index.html" title="Chapter&#160;1.&#160;Boost.TypeIndex 1.0">
<link rel="up" href="../boost_typeindex_header_reference.html#header.boost.type_index.type_index_impl_hpp" title="Header &lt;boost/type_index/type_index_impl.hpp&gt;">
<link rel="prev" href="type_id_rtti_on_idp5760464.html" title="Function template type_id_rtti_only">
<link rel="prev" href="type_id_rtti_on_idp5430736.html" title="Function template type_id_rtti_only">
<link rel="next" href="../boost_typeindex/space_and_performance.html" title="Space and Performance">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -20,10 +20,10 @@
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="type_id_rtti_on_idp5760464.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../boost_typeindex_header_reference.html#header.boost.type_index.type_index_impl_hpp"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../index.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="../boost_typeindex/space_and_performance.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/next.png" alt="Next"></a>
<a accesskey="p" href="type_id_rtti_on_idp5430736.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../boost_typeindex_header_reference.html#header.boost.type_index.type_index_impl_hpp"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../index.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="../boost_typeindex/space_and_performance.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/next.png" alt="Next"></a>
</div>
<div class="refentry">
<a name="boost.type_id_rtti_on_idp5763792"></a><div class="titlepage"></div>
<a name="boost.type_id_rtti_on_idp5434192"></a><div class="titlepage"></div>
<div class="refnamediv">
<h2><span class="refentrytitle">Function template type_id_rtti_only</span></h2>
<p>boost::type_id_rtti_only</p>
@@ -34,7 +34,7 @@
</span>
<span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">typename</span> T<span class="special">&gt;</span> <a class="link" href="type_index.html" title="Class type_index">type_index</a> <span class="identifier">type_id_rtti_only</span><span class="special">(</span><span class="identifier">T</span> <span class="special">*</span> rtti_val<span class="special">)</span><span class="special">;</span></pre></div>
<div class="refsect1">
<a name="idp34952464"></a><h2>Description</h2>
<a name="idp62319888"></a><h2>Description</h2>
<p>Function, that works exactly like C++ typeid(rtti_val) call, but returns <code class="computeroutput"><a class="link" href="type_index.html" title="Class type_index">boost::type_index</a></code>. This method available only with RTTI enabled. Without RTTI support it won't compile, producing a compile-time error with message: "boost::type_id_rtti_only(T*) requires RTTI" </p>
</div>
</div>
@@ -48,7 +48,7 @@
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="type_id_rtti_on_idp5760464.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../boost_typeindex_header_reference.html#header.boost.type_index.type_index_impl_hpp"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../index.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="../boost_typeindex/space_and_performance.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/next.png" alt="Next"></a>
<a accesskey="p" href="type_id_rtti_on_idp5430736.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../boost_typeindex_header_reference.html#header.boost.type_index.type_index_impl_hpp"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../index.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="../boost_typeindex/space_and_performance.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -7,7 +7,7 @@
<link rel="home" href="../index.html" title="Chapter&#160;1.&#160;Boost.TypeIndex 1.0">
<link rel="up" href="../boost_typeindex_header_reference.html#header.boost.type_index.type_index_impl_hpp" title="Header &lt;boost/type_index/type_index_impl.hpp&gt;">
<link rel="prev" href="type_id.html" title="Function template type_id">
<link rel="next" href="type_id_rtti_on_idp5760464.html" title="Function template type_id_rtti_only">
<link rel="next" href="type_id_rtti_on_idp5430736.html" title="Function template type_id_rtti_only">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -20,7 +20,7 @@
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="type_id.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../boost_typeindex_header_reference.html#header.boost.type_index.type_index_impl_hpp"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../index.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="type_id_rtti_on_idp5760464.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/next.png" alt="Next"></a>
<a accesskey="p" href="type_id.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../boost_typeindex_header_reference.html#header.boost.type_index.type_index_impl_hpp"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../index.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="type_id_rtti_on_idp5430736.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/next.png" alt="Next"></a>
</div>
<div class="refentry">
<a name="boost.type_id_with_cvr"></a><div class="titlepage"></div>
@@ -34,7 +34,7 @@
</span>
<span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">typename</span> T<span class="special">&gt;</span> <a class="link" href="type_index.html" title="Class type_index">type_index</a> <span class="identifier">type_id_with_cvr</span><span class="special">(</span><span class="special">)</span><span class="special">;</span></pre></div>
<div class="refsect1">
<a name="idp34929792"></a><h2>Description</h2>
<a name="idp62297216"></a><h2>Description</h2>
<p>Function for constructing <code class="computeroutput"><a class="link" href="type_index.html" title="Class type_index">type_index</a></code> instance for type T. Does not strip const, volatile, &amp; and &amp;&amp; modifiers from T. If T has no const, volatile, &amp; and &amp;&amp; modifiers, then returns exactly the same result as in case of calling `type_id&lt;T&gt;()`. </p>
</div>
</div>
@@ -48,7 +48,7 @@
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="type_id.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../boost_typeindex_header_reference.html#header.boost.type_index.type_index_impl_hpp"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../index.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="type_id_rtti_on_idp5760464.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/next.png" alt="Next"></a>
<a accesskey="p" href="type_id.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../boost_typeindex_header_reference.html#header.boost.type_index.type_index_impl_hpp"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../index.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="type_id_rtti_on_idp5430736.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -38,69 +38,69 @@
<span class="keyword">typedef</span> <span class="identifier">std</span><span class="special">::</span><span class="identifier">type_info</span> <a name="boost.type_index.stl_type_info"></a><span class="identifier">stl_type_info</span><span class="special">;</span>
<span class="comment">// <a class="link" href="type_index.html#boost.type_indexconstruct-copy-destruct">construct/copy/destruct</a></span>
<a class="link" href="type_index.html#idp5739600-bb"><span class="identifier">type_index</span></a><span class="special">(</span><span class="special">)</span><span class="special">;</span>
<span class="keyword">explicit</span> <a class="link" href="type_index.html#idp5739984-bb"><span class="identifier">type_index</span></a><span class="special">(</span><span class="keyword">const</span> <span class="identifier">stl_type_info</span> <span class="special">&amp;</span><span class="special">)</span><span class="special">;</span>
<a class="link" href="type_index.html#idp5408016-bb"><span class="identifier">type_index</span></a><span class="special">(</span><span class="special">)</span> <span class="keyword">noexcept</span><span class="special">;</span>
<span class="keyword">explicit</span> <a class="link" href="type_index.html#idp5408768-bb"><span class="identifier">type_index</span></a><span class="special">(</span><span class="keyword">const</span> <span class="identifier">stl_type_info</span> <span class="special">&amp;</span><span class="special">)</span> <span class="keyword">noexcept</span><span class="special">;</span>
<span class="comment">// <a class="link" href="type_index.html#idp5733712-bb">public member functions</a></span>
<span class="keyword">bool</span> <a class="link" href="type_index.html#idp5733968-bb"><span class="identifier">before</span></a><span class="special">(</span><a class="link" href="type_index.html" title="Class type_index">type_index</a> <span class="keyword">const</span> <span class="special">&amp;</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span>
<span class="keyword">const</span> <span class="keyword">char</span> <span class="special">*</span> <a class="link" href="type_index.html#idp5736240-bb"><span class="identifier">name</span></a><span class="special">(</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span>
<span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span> <a class="link" href="type_index.html#idp5737360-bb"><span class="identifier">name_demangled</span></a><span class="special">(</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span>
<span class="identifier">std</span><span class="special">::</span><span class="identifier">size_t</span> <a class="link" href="type_index.html#idp5738480-bb"><span class="identifier">hash_code</span></a><span class="special">(</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span>
<span class="comment">// <a class="link" href="type_index.html#idp5401248-bb">public member functions</a></span>
<span class="keyword">bool</span> <a class="link" href="type_index.html#idp5401744-bb"><span class="identifier">before</span></a><span class="special">(</span><a class="link" href="type_index.html" title="Class type_index">type_index</a> <span class="keyword">const</span> <span class="special">&amp;</span><span class="special">)</span> <span class="keyword">const</span> <span class="keyword">noexcept</span><span class="special">;</span>
<span class="keyword">const</span> <span class="keyword">char</span> <span class="special">*</span> <a class="link" href="type_index.html#idp5404144-bb"><span class="identifier">name</span></a><span class="special">(</span><span class="special">)</span> <span class="keyword">const</span> <span class="keyword">noexcept</span><span class="special">;</span>
<span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span> <a class="link" href="type_index.html#idp5405392-bb"><span class="identifier">name_demangled</span></a><span class="special">(</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span>
<span class="identifier">std</span><span class="special">::</span><span class="identifier">size_t</span> <a class="link" href="type_index.html#idp5406640-bb"><span class="identifier">hash_code</span></a><span class="special">(</span><span class="special">)</span> <span class="keyword">const</span> <span class="keyword">noexcept</span><span class="special">;</span>
<span class="comment">// <a class="link" href="type_index.html#idp5741856-bb">public static functions</a></span>
<span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">typename</span> T<span class="special">&gt;</span> <span class="keyword">static</span> <a class="link" href="type_index.html" title="Class type_index">type_index</a> <a class="link" href="type_index.html#idp5742224-bb"><span class="identifier">construct</span></a><span class="special">(</span><span class="special">)</span><span class="special">;</span>
<span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">typename</span> T<span class="special">&gt;</span> <span class="keyword">static</span> <a class="link" href="type_index.html" title="Class type_index">type_index</a> <a class="link" href="type_index.html#idp5745104-bb"><span class="identifier">construct_with_cvr</span></a><span class="special">(</span><span class="special">)</span><span class="special">;</span>
<span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">typename</span> T<span class="special">&gt;</span> <span class="keyword">static</span> <a class="link" href="type_index.html" title="Class type_index">type_index</a> <a class="link" href="type_index.html#idp5748208-bb"><span class="identifier">construct_rtti_only</span></a><span class="special">(</span><span class="identifier">T</span> <span class="special">&amp;</span><span class="special">)</span><span class="special">;</span>
<span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">typename</span> T<span class="special">&gt;</span> <span class="keyword">static</span> <a class="link" href="type_index.html" title="Class type_index">type_index</a> <a class="link" href="type_index.html#idp5751712-bb"><span class="identifier">construct_rtti_only</span></a><span class="special">(</span><span class="identifier">T</span> <span class="special">*</span><span class="special">)</span><span class="special">;</span>
<span class="comment">// <a class="link" href="type_index.html#idp5411008-bb">public static functions</a></span>
<span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">typename</span> T<span class="special">&gt;</span> <span class="keyword">static</span> <a class="link" href="type_index.html" title="Class type_index">type_index</a> <a class="link" href="type_index.html#idp5411504-bb"><span class="identifier">construct</span></a><span class="special">(</span><span class="special">)</span> <span class="keyword">noexcept</span><span class="special">;</span>
<span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">typename</span> T<span class="special">&gt;</span> <span class="keyword">static</span> <a class="link" href="type_index.html" title="Class type_index">type_index</a> <a class="link" href="type_index.html#idp5414624-bb"><span class="identifier">construct_with_cvr</span></a><span class="special">(</span><span class="special">)</span> <span class="keyword">noexcept</span><span class="special">;</span>
<span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">typename</span> T<span class="special">&gt;</span> <span class="keyword">static</span> <a class="link" href="type_index.html" title="Class type_index">type_index</a> <a class="link" href="type_index.html#idp5417968-bb"><span class="identifier">construct_rtti_only</span></a><span class="special">(</span><span class="identifier">T</span> <span class="special">&amp;</span><span class="special">)</span><span class="special">;</span>
<span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">typename</span> T<span class="special">&gt;</span> <span class="keyword">static</span> <a class="link" href="type_index.html" title="Class type_index">type_index</a> <a class="link" href="type_index.html#idp5421472-bb"><span class="identifier">construct_rtti_only</span></a><span class="special">(</span><span class="identifier">T</span> <span class="special">*</span><span class="special">)</span><span class="special">;</span>
<span class="special">}</span><span class="special">;</span></pre></div>
<div class="refsect1">
<a name="idp34837200"></a><h2>Description</h2>
<a name="idp62200256"></a><h2>Description</h2>
<div class="refsect2">
<a name="idp34837584"></a><h3>
<a name="idp62200640"></a><h3>
<a name="boost.type_indexconstruct-copy-destruct"></a><code class="computeroutput">type_index</code>
public
construct/copy/destruct</h3>
<div class="orderedlist"><ol class="orderedlist" type="1">
<li class="listitem">
<pre class="literallayout"><a name="idp5739600-bb"></a><span class="identifier">type_index</span><span class="special">(</span><span class="special">)</span><span class="special">;</span></pre>Default constructor. </li>
<pre class="literallayout"><a name="idp5408016-bb"></a><span class="identifier">type_index</span><span class="special">(</span><span class="special">)</span> <span class="keyword">noexcept</span><span class="special">;</span></pre>Default constructor. </li>
<li class="listitem">
<pre class="literallayout"><span class="keyword">explicit</span> <a name="idp5739984-bb"></a><span class="identifier">type_index</span><span class="special">(</span><span class="keyword">const</span> <span class="identifier">stl_type_info</span> <span class="special">&amp;</span> inf<span class="special">)</span><span class="special">;</span></pre>Constructs <code class="computeroutput"><a class="link" href="type_index.html" title="Class type_index">type_index</a></code> from an instance of std::type_info. </li>
<pre class="literallayout"><span class="keyword">explicit</span> <a name="idp5408768-bb"></a><span class="identifier">type_index</span><span class="special">(</span><span class="keyword">const</span> <span class="identifier">stl_type_info</span> <span class="special">&amp;</span> inf<span class="special">)</span> <span class="keyword">noexcept</span><span class="special">;</span></pre>Constructs <code class="computeroutput"><a class="link" href="type_index.html" title="Class type_index">type_index</a></code> from an instance of std::type_info. </li>
</ol></div>
</div>
<div class="refsect2">
<a name="idp34849616"></a><h3>
<a name="idp5733712-bb"></a><code class="computeroutput">type_index</code> public member functions</h3>
<a name="idp62213920"></a><h3>
<a name="idp5401248-bb"></a><code class="computeroutput">type_index</code> public member functions</h3>
<div class="orderedlist"><ol class="orderedlist" type="1">
<li class="listitem">
<pre class="literallayout"><span class="keyword">bool</span> <a name="idp5733968-bb"></a><span class="identifier">before</span><span class="special">(</span><a class="link" href="type_index.html" title="Class type_index">type_index</a> <span class="keyword">const</span> <span class="special">&amp;</span> rhs<span class="special">)</span> <span class="keyword">const</span><span class="special">;</span></pre>
<pre class="literallayout"><span class="keyword">bool</span> <a name="idp5401744-bb"></a><span class="identifier">before</span><span class="special">(</span><a class="link" href="type_index.html" title="Class type_index">type_index</a> <span class="keyword">const</span> <span class="special">&amp;</span> rhs<span class="special">)</span> <span class="keyword">const</span> <span class="keyword">noexcept</span><span class="special">;</span></pre>
<p>Returns true if the type precedes the type of rhs in the collation order. The collation order is just an internal order. </p>
</li>
<li class="listitem">
<pre class="literallayout"><span class="keyword">const</span> <span class="keyword">char</span> <span class="special">*</span> <a name="idp5736240-bb"></a><span class="identifier">name</span><span class="special">(</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span></pre>Returns raw name. </li>
<pre class="literallayout"><span class="keyword">const</span> <span class="keyword">char</span> <span class="special">*</span> <a name="idp5404144-bb"></a><span class="identifier">name</span><span class="special">(</span><span class="special">)</span> <span class="keyword">const</span> <span class="keyword">noexcept</span><span class="special">;</span></pre>Returns raw name. </li>
<li class="listitem">
<pre class="literallayout"><span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span> <a name="idp5737360-bb"></a><span class="identifier">name_demangled</span><span class="special">(</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span></pre>Returns user-friendly name. </li>
<pre class="literallayout"><span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span> <a name="idp5405392-bb"></a><span class="identifier">name_demangled</span><span class="special">(</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span></pre>Returns user-friendly name. </li>
<li class="listitem">
<pre class="literallayout"><span class="identifier">std</span><span class="special">::</span><span class="identifier">size_t</span> <a name="idp5738480-bb"></a><span class="identifier">hash_code</span><span class="special">(</span><span class="special">)</span> <span class="keyword">const</span><span class="special">;</span></pre>Function for getting hash value. </li>
<pre class="literallayout"><span class="identifier">std</span><span class="special">::</span><span class="identifier">size_t</span> <a name="idp5406640-bb"></a><span class="identifier">hash_code</span><span class="special">(</span><span class="special">)</span> <span class="keyword">const</span> <span class="keyword">noexcept</span><span class="special">;</span></pre>Function for getting hash value. </li>
</ol></div>
</div>
<div class="refsect2">
<a name="idp34875216"></a><h3>
<a name="idp5741856-bb"></a><code class="computeroutput">type_index</code> public static functions</h3>
<a name="idp62241392"></a><h3>
<a name="idp5411008-bb"></a><code class="computeroutput">type_index</code> public static functions</h3>
<div class="orderedlist"><ol class="orderedlist" type="1">
<li class="listitem">
<pre class="literallayout"><span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">typename</span> T<span class="special">&gt;</span> <span class="keyword">static</span> <a class="link" href="type_index.html" title="Class type_index">type_index</a> <a name="idp5742224-bb"></a><span class="identifier">construct</span><span class="special">(</span><span class="special">)</span><span class="special">;</span></pre>
<pre class="literallayout"><span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">typename</span> T<span class="special">&gt;</span> <span class="keyword">static</span> <a class="link" href="type_index.html" title="Class type_index">type_index</a> <a name="idp5411504-bb"></a><span class="identifier">construct</span><span class="special">(</span><span class="special">)</span> <span class="keyword">noexcept</span><span class="special">;</span></pre>
<p>Factory method for constructing <code class="computeroutput"><a class="link" href="type_index.html" title="Class type_index">type_index</a></code> instance for type T. Strips const, volatile and &amp; modifiers from T. </p>
</li>
<li class="listitem">
<pre class="literallayout"><span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">typename</span> T<span class="special">&gt;</span> <span class="keyword">static</span> <a class="link" href="type_index.html" title="Class type_index">type_index</a> <a name="idp5745104-bb"></a><span class="identifier">construct_with_cvr</span><span class="special">(</span><span class="special">)</span><span class="special">;</span></pre>
<pre class="literallayout"><span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">typename</span> T<span class="special">&gt;</span> <span class="keyword">static</span> <a class="link" href="type_index.html" title="Class type_index">type_index</a> <a name="idp5414624-bb"></a><span class="identifier">construct_with_cvr</span><span class="special">(</span><span class="special">)</span> <span class="keyword">noexcept</span><span class="special">;</span></pre>
<p>Factory method for constructing <code class="computeroutput"><a class="link" href="type_index.html" title="Class type_index">type_index</a></code> instance for type T. Does not strip const, volatile, &amp; and &amp;&amp; modifiers from T. If T has no const, volatile, &amp; and &amp;&amp; modifiers, then returns exactly the same result as in case of calling `construct&lt;T&gt;()`. </p>
</li>
<li class="listitem">
<pre class="literallayout"><span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">typename</span> T<span class="special">&gt;</span> <span class="keyword">static</span> <a class="link" href="type_index.html" title="Class type_index">type_index</a> <a name="idp5748208-bb"></a><span class="identifier">construct_rtti_only</span><span class="special">(</span><span class="identifier">T</span> <span class="special">&amp;</span> rtti_val<span class="special">)</span><span class="special">;</span></pre>
<pre class="literallayout"><span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">typename</span> T<span class="special">&gt;</span> <span class="keyword">static</span> <a class="link" href="type_index.html" title="Class type_index">type_index</a> <a name="idp5417968-bb"></a><span class="identifier">construct_rtti_only</span><span class="special">(</span><span class="identifier">T</span> <span class="special">&amp;</span> rtti_val<span class="special">)</span><span class="special">;</span></pre>
<p>Factory function, that works exactly like C++ typeid(rtti_val) call, but returns <code class="computeroutput"><a class="link" href="type_index.html" title="Class type_index">boost::type_index</a></code>. This method available only with RTTI enabled. </p>
</li>
<li class="listitem">
<pre class="literallayout"><span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">typename</span> T<span class="special">&gt;</span> <span class="keyword">static</span> <a class="link" href="type_index.html" title="Class type_index">type_index</a> <a name="idp5751712-bb"></a><span class="identifier">construct_rtti_only</span><span class="special">(</span><span class="identifier">T</span> <span class="special">*</span> rtti_val<span class="special">)</span><span class="special">;</span></pre>
<pre class="literallayout"><span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">typename</span> T<span class="special">&gt;</span> <span class="keyword">static</span> <a class="link" href="type_index.html" title="Class type_index">type_index</a> <a name="idp5421472-bb"></a><span class="identifier">construct_rtti_only</span><span class="special">(</span><span class="identifier">T</span> <span class="special">*</span> rtti_val<span class="special">)</span><span class="special">;</span></pre>
<p>Factory function, that works exactly like C++ typeid(rtti_val) call, but returns <code class="computeroutput"><a class="link" href="type_index.html" title="Class type_index">boost::type_index</a></code>. This method available only with RTTI enabled. </p>
</li>
</ol></div>

View File

@@ -7,6 +7,7 @@
<link rel="home" href="../index.html" title="Chapter&#160;1.&#160;Boost.TypeIndex 1.0">
<link rel="up" href="../index.html" title="Chapter&#160;1.&#160;Boost.TypeIndex 1.0">
<link rel="prev" href="code_bloat.html" title="Code bloat">
<link rel="next" href="mixing_sources_with_rtti_on_and_rtti_off.html" title="Mixing sources with RTTI on and RTTI off">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
@@ -19,7 +20,7 @@
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="code_bloat.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../index.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../index.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/home.png" alt="Home"></a>
<a accesskey="p" href="code_bloat.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../index.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../index.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="mixing_sources_with_rtti_on_and_rtti_off.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h2 class="title" style="clear: both">
@@ -84,7 +85,7 @@
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="code_bloat.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../index.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../index.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/home.png" alt="Home"></a>
<a accesskey="p" href="code_bloat.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../index.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../index.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="mixing_sources_with_rtti_on_and_rtti_off.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -0,0 +1,105 @@
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=US-ASCII">
<title>Mixing sources with RTTI on and RTTI off</title>
<link rel="stylesheet" href="http://www.boost.org/doc/libs/1_53_0/doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.75.2">
<link rel="home" href="../index.html" title="Chapter&#160;1.&#160;Boost.TypeIndex 1.0">
<link rel="up" href="../index.html" title="Chapter&#160;1.&#160;Boost.TypeIndex 1.0">
<link rel="prev" href="compiler_support.html" title="Compiler support">
</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="http://www.boost.org/doc/libs/1_53_0/boost.png"></td>
<td align="center"><a href="http://www.boost.org/doc/libs/1_53_0/index.html">Home</a></td>
<td align="center"><a href="http://www.boost.org/doc/libs/1_53_0/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="http://www.boost.org/doc/libs/1_53_0/more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="compiler_support.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../index.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../index.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/home.png" alt="Home"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h2 class="title" style="clear: both">
<a name="boost_typeindex.mixing_sources_with_rtti_on_and_rtti_off"></a><a class="link" href="mixing_sources_with_rtti_on_and_rtti_off.html" title="Mixing sources with RTTI on and RTTI off">Mixing
sources with RTTI on and RTTI off</a>
</h2></div></div></div>
<p>
Linking a binary from source files that were compiled with different RTTI flags
is not a very good idea and may lead to a lot of surprises. However if there
is a very strong need TypeIndex library provides a solution for mixing sources:
just define <code class="computeroutput"><span class="identifier">BOOST_TYPE_INDEX_FORCE_NORTTI_COMPATIBILITY</span></code>
macro. This would lead to usage of <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">template_index</span></code>
instead of <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">type_index</span></code> class.
</p>
<div class="note"><table border="0" summary="Note">
<tr>
<td rowspan="2" align="center" valign="top" width="25"><img alt="[Note]" src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/note.png"></td>
<th align="left">Note</th>
</tr>
<tr><td align="left" valign="top"><p>
Do not forget to rebuild <span class="bold"><strong>all</strong></span> the projects
with <code class="computeroutput"><span class="identifier">BOOST_TYPE_INDEX_FORCE_NORTTI_COMPATIBILITY</span></code>
macro defined
</p></td></tr>
</table></div>
<p>
You must know that linking RTTI on and RTTI off binaries may succeed even without
defining the <code class="computeroutput"><span class="identifier">BOOST_TYPE_INDEX_FORCE_NORTTI_COMPATIBILITY</span></code>
macro, but that does not mean that you'll get a working binary. Such actions
may break the One Definition Rule. Take a look at the table below, that shows
how the <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">type_index</span> <span class="identifier">get_integer</span><span class="special">();</span></code> function will look like with different RTTI
flags:
</p>
<div class="informaltable">
<a name="boost_typeindex.mixing_sources_with_rtti_on_and_rtti_off.diffs"></a><table class="table">
<colgroup>
<col>
<col>
</colgroup>
<thead><tr>
<th>
<p>
RTTI on
</p>
</th>
<th>
<p>
RTTI off
</p>
</th>
</tr></thead>
<tbody><tr>
<td>
<p>
<code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">type_index</span> <span class="identifier">get_integer</span><span class="special">();</span></code>
</p>
</td>
<td>
<p>
<code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">template_index</span> <span class="identifier">get_integer</span><span class="special">();</span></code>
</p>
</td>
</tr></tbody>
</table>
</div>
<p>
Such differences are usually not detected by linker and lead to errors at runtime.
</p>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright &#169; 2012, 2013 Antony Polukhin<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></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="compiler_support.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../index.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../index.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/home.png" alt="Home"></a>
</div>
</body>
</html>

View File

@@ -6,7 +6,7 @@
<meta name="generator" content="DocBook XSL Stylesheets V1.75.2">
<link rel="home" href="../index.html" title="Chapter&#160;1.&#160;Boost.TypeIndex 1.0">
<link rel="up" href="../index.html" title="Chapter&#160;1.&#160;Boost.TypeIndex 1.0">
<link rel="prev" href="../boost/type_id_rtti_on_idp5763792.html" title="Function template type_id_rtti_only">
<link rel="prev" href="../boost/type_id_rtti_on_idp5434192.html" title="Function template type_id_rtti_only">
<link rel="next" href="code_bloat.html" title="Code bloat">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
@@ -20,7 +20,7 @@
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="../boost/type_id_rtti_on_idp5763792.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../index.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../index.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="code_bloat.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/next.png" alt="Next"></a>
<a accesskey="p" href="../boost/type_id_rtti_on_idp5434192.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../index.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../index.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="code_bloat.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h2 class="title" style="clear: both">
@@ -69,7 +69,7 @@
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="../boost/type_id_rtti_on_idp5763792.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../index.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../index.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="code_bloat.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/next.png" alt="Next"></a>
<a accesskey="p" href="../boost/type_id_rtti_on_idp5434192.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../index.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../index.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="code_bloat.html"><img src="http://www.boost.org/doc/libs/1_53_0/doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>

View File

@@ -51,7 +51,7 @@
<span class="comment">// Ostream operator that will output demangled name. </span>
<span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">typename</span> CharT<span class="special">,</span> <span class="keyword">typename</span> TriatT<span class="special">&gt;</span>
<span class="identifier">std</span><span class="special">::</span><span class="identifier">basic_ostream</span><span class="special">&lt;</span> <span class="identifier">CharT</span><span class="special">,</span> <span class="identifier">TriatT</span> <span class="special">&gt;</span> <span class="special">&amp;</span>
<a name="boost.operator_idm11920"></a><span class="keyword">operator</span><span class="special">&lt;&lt;</span><span class="special">(</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">basic_ostream</span><span class="special">&lt;</span> <span class="identifier">CharT</span><span class="special">,</span> <span class="identifier">TriatT</span> <span class="special">&gt;</span> <span class="special">&amp;</span> ostr<span class="special">,</span>
<a name="boost.operator_idm17536"></a><span class="keyword">operator</span><span class="special">&lt;&lt;</span><span class="special">(</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">basic_ostream</span><span class="special">&lt;</span> <span class="identifier">CharT</span><span class="special">,</span> <span class="identifier">TriatT</span> <span class="special">&gt;</span> <span class="special">&amp;</span> ostr<span class="special">,</span>
<a class="link" href="boost/template_index.html" title="Class template_index">template_index</a> <span class="keyword">const</span> <span class="special">&amp;</span> ind<span class="special">)</span><span class="special">;</span>
<span class="comment">// hash_value function overload for <a class="link" href="boost/template_index.html" title="Class template_index">template_index</a></span>
@@ -67,15 +67,16 @@
<span class="keyword">class</span> <a class="link" href="boost/type_index.html" title="Class type_index">type_index</a><span class="special">;</span>
<span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">typename</span> T<span class="special">&gt;</span> <a class="link" href="boost/type_index.html" title="Class type_index">type_index</a> <a class="link" href="boost/type_id.html" title="Function template type_id"><span class="identifier">type_id</span></a><span class="special">(</span><span class="special">)</span><span class="special">;</span>
<span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">typename</span> T<span class="special">&gt;</span> <a class="link" href="boost/type_index.html" title="Class type_index">type_index</a> <a class="link" href="boost/type_id_with_cvr.html" title="Function template type_id_with_cvr"><span class="identifier">type_id_with_cvr</span></a><span class="special">(</span><span class="special">)</span><span class="special">;</span>
<span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">typename</span> T<span class="special">&gt;</span> <a class="link" href="boost/type_index.html" title="Class type_index">type_index</a> <a class="link" href="boost/type_id_rtti_on_idp5760464.html" title="Function template type_id_rtti_only"><span class="identifier">type_id_rtti_only</span></a><span class="special">(</span><span class="identifier">T</span> <span class="special">&amp;</span><span class="special">)</span><span class="special">;</span>
<span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">typename</span> T<span class="special">&gt;</span> <a class="link" href="boost/type_index.html" title="Class type_index">type_index</a> <a class="link" href="boost/type_id_rtti_on_idp5763792.html" title="Function template type_id_rtti_only"><span class="identifier">type_id_rtti_only</span></a><span class="special">(</span><span class="identifier">T</span> <span class="special">*</span><span class="special">)</span><span class="special">;</span>
<span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">typename</span> T<span class="special">&gt;</span> <a class="link" href="boost/type_index.html" title="Class type_index">type_index</a> <a class="link" href="boost/type_id_rtti_on_idp5430736.html" title="Function template type_id_rtti_only"><span class="identifier">type_id_rtti_only</span></a><span class="special">(</span><span class="identifier">T</span> <span class="special">&amp;</span><span class="special">)</span><span class="special">;</span>
<span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">typename</span> T<span class="special">&gt;</span> <a class="link" href="boost/type_index.html" title="Class type_index">type_index</a> <a class="link" href="boost/type_id_rtti_on_idp5434192.html" title="Function template type_id_rtti_only"><span class="identifier">type_id_rtti_only</span></a><span class="special">(</span><span class="identifier">T</span> <span class="special">*</span><span class="special">)</span><span class="special">;</span>
<span class="special">}</span></pre>
</div>
<div class="section">
<div class="titlepage"><div><div><h3 class="title">
<a name="header.boost.type_index.type_index_minimal_hpp"></a>Header &lt;<a href="http://www.boost.org/doc/libs/1_53_0/boost/type_index/type_index_minimal.hpp" target="_top">boost/type_index/type_index_minimal.hpp</a>&gt;</h3></div></div></div>
<p>This is the header that required for ussage of type_index with/without RTTI. </p>
<p>It includes only the minamally required headers and does the `typedef template_index type_index;` when RTTI is disabled. </p>
<p>It includes only the minamally required headers and does the `typedef template_index type_index;` when RTTI is disabled.</p>
<p>Define the BOOST_TYPE_INDEX_FORCE_NORTTI_COMPATIBILITY macro if you are mixing objects compiled with different RTTI flags. </p>
</div>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>

View File

@@ -56,6 +56,8 @@
<dt><span class="section"><a href="boost_typeindex/space_and_performance.html">Space and Performance</a></span></dt>
<dt><span class="section"><a href="boost_typeindex/code_bloat.html">Code bloat</a></span></dt>
<dt><span class="section"><a href="boost_typeindex/compiler_support.html">Compiler support</a></span></dt>
<dt><span class="section"><a href="boost_typeindex/mixing_sources_with_rtti_on_and_rtti_off.html">Mixing
sources with RTTI on and RTTI off</a></span></dt>
</dl>
</div>
<div class="section">
@@ -119,7 +121,7 @@
</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: October 17, 2013 at 07:39:53 GMT</small></p></td>
<td align="left"><p><small>Last revised: October 22, 2013 at 12:36:27 GMT</small></p></td>
<td align="right"><div class="copyright-footer"></div></td>
</tr></table>
<hr>

View File

@@ -8,8 +8,9 @@ boost/template_id_with_cvr.html
boost/type_index.html
boost/type_id.html
boost/type_id_with_cvr.html
boost/type_id_rtti_on_idp5760464.html
boost/type_id_rtti_on_idp5763792.html
boost/type_id_rtti_on_idp5430736.html
boost/type_id_rtti_on_idp5434192.html
boost_typeindex/space_and_performance.html
boost_typeindex/code_bloat.html
boost_typeindex/compiler_support.html
boost_typeindex/mixing_sources_with_rtti_on_and_rtti_off.html