]> git.proxmox.com Git - ceph.git/blob - ceph/src/boost/libs/multiprecision/doc/html/boost_multiprecision/ref/cpp_dec_ref.html
bump version to 12.2.2-pve1
[ceph.git] / ceph / src / boost / libs / multiprecision / doc / html / boost_multiprecision / ref / cpp_dec_ref.html
1 <html>
2 <head>
3 <meta http-equiv="Content-Type" content="text/html; charset=US-ASCII">
4 <title>cpp_dec_float</title>
5 <link rel="stylesheet" href="../../../../../../doc/src/boostbook.css" type="text/css">
6 <meta name="generator" content="DocBook XSL Stylesheets V1.77.1">
7 <link rel="home" href="../../index.html" title="Chapter&#160;1.&#160;Boost.Multiprecision">
8 <link rel="up" href="../ref.html" title="Reference">
9 <link rel="prev" href="cpp_bin_float_ref.html" title="cpp_bin_float">
10 <link rel="next" href="internals.html" title="Internal Support Code">
11 </head>
12 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
13 <table cellpadding="2" width="100%"><tr>
14 <td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../boost.png"></td>
15 <td align="center"><a href="../../../../../../index.html">Home</a></td>
16 <td align="center"><a href="../../../../../../libs/libraries.htm">Libraries</a></td>
17 <td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
18 <td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
19 <td align="center"><a href="../../../../../../more/index.htm">More</a></td>
20 </tr></table>
21 <hr>
22 <div class="spirit-nav">
23 <a accesskey="p" href="cpp_bin_float_ref.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../ref.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../index.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="internals.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
24 </div>
25 <div class="section">
26 <div class="titlepage"><div><div><h3 class="title">
27 <a name="boost_multiprecision.ref.cpp_dec_ref"></a><a class="link" href="cpp_dec_ref.html" title="cpp_dec_float">cpp_dec_float</a>
28 </h3></div></div></div>
29 <pre class="programlisting"><span class="keyword">namespace</span> <span class="identifier">boost</span><span class="special">{</span> <span class="keyword">namespace</span> <span class="identifier">multiprecision</span><span class="special">{</span>
30
31 <span class="keyword">template</span> <span class="special">&lt;</span><span class="keyword">unsigned</span> <span class="identifier">Digits10</span><span class="special">,</span> <span class="keyword">class</span> <span class="identifier">ExponentType</span> <span class="special">=</span> <span class="identifier">boost</span><span class="special">::</span><span class="identifier">int32_t</span><span class="special">,</span> <span class="keyword">class</span> <span class="identifier">Allocator</span> <span class="special">=</span> <span class="keyword">void</span><span class="special">&gt;</span>
32 <span class="keyword">class</span> <span class="identifier">cpp_dec_float</span><span class="special">;</span>
33
34 <span class="keyword">typedef</span> <span class="identifier">number</span><span class="special">&lt;</span><span class="identifier">cpp_dec_float</span><span class="special">&lt;</span><span class="number">50</span><span class="special">&gt;</span> <span class="special">&gt;</span> <span class="identifier">cpp_dec_float_50</span><span class="special">;</span>
35 <span class="keyword">typedef</span> <span class="identifier">number</span><span class="special">&lt;</span><span class="identifier">cpp_dec_float</span><span class="special">&lt;</span><span class="number">100</span><span class="special">&gt;</span> <span class="special">&gt;</span> <span class="identifier">cpp_dec_float_100</span><span class="special">;</span>
36
37 <span class="special">}}</span> <span class="comment">// namespaces</span>
38 </pre>
39 <p>
40 Class template <code class="computeroutput"><span class="identifier">cpp_dec_float</span></code>
41 fulfils all of the requirements for a <a class="link" href="backendconc.html" title="Backend Requirements">Backend</a>
42 type. Its members and non-member functions are deliberately not documented:
43 these are considered implementation details that are subject to change.
44 </p>
45 <p>
46 The class takes three template parameters:
47 </p>
48 <div class="variablelist">
49 <p class="title"><b></b></p>
50 <dl class="variablelist">
51 <dt><span class="term">Digits10</span></dt>
52 <dd><p>
53 The number of decimal digits precision the type should support. Note
54 that this type does not normally perform any dynamic memory allocation,
55 and as a result the <code class="computeroutput"><span class="identifier">Digits10</span></code>
56 template argument should not be set too high or the class's size will
57 grow unreasonably large.
58 </p></dd>
59 <dt><span class="term">ExponentType</span></dt>
60 <dd><p>
61 A signed integer type that represents the exponent of the number
62 </p></dd>
63 <dt><span class="term">Allocator</span></dt>
64 <dd><p>
65 The allocator used: defaults to type <code class="computeroutput"><span class="keyword">void</span></code>,
66 meaning all storage is within the class, and no dynamic allocation
67 is performed, but can be set to a standard library allocator if dynamic
68 allocation makes more sense.
69 </p></dd>
70 </dl>
71 </div>
72 <p>
73 The type of <code class="computeroutput"><span class="identifier">number_category</span><span class="special">&lt;</span><span class="identifier">cpp_dec_float</span><span class="special">&lt;</span><span class="identifier">Args</span><span class="special">...&gt;</span> <span class="special">&gt;::</span><span class="identifier">type</span></code> is <code class="computeroutput"><span class="identifier">mpl</span><span class="special">::</span><span class="identifier">int_</span><span class="special">&lt;</span><span class="identifier">number_kind_floating_point</span><span class="special">&gt;</span></code>.
74 </p>
75 <p>
76 More information on this type can be found in the <a class="link" href="../tut/floats/cpp_dec_float.html" title="cpp_dec_float">tutorial</a>.
77 </p>
78 </div>
79 <table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
80 <td align="left"></td>
81 <td align="right"><div class="copyright-footer">Copyright &#169; 2002-2013 John Maddock and Christopher Kormanyos<p>
82 Distributed under the Boost Software License, Version 1.0. (See accompanying
83 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>)
84 </p>
85 </div></td>
86 </tr></table>
87 <hr>
88 <div class="spirit-nav">
89 <a accesskey="p" href="cpp_bin_float_ref.html"><img src="../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../ref.html"><img src="../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../index.html"><img src="../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="internals.html"><img src="../../../../../../doc/src/images/next.png" alt="Next"></a>
90 </div>
91 </body>
92 </html>