1 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
4 <meta http-equiv="Content-Type" content="text/html; charset=US-ASCII">
5 <title>Change Log</title>
6 <link rel="stylesheet" href="../../../doc/src/boostbook.css" type="text/css">
7 <meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
8 <link rel="home" href="../index.html" title="The Boost C++ Libraries BoostBook Documentation Subset">
9 <link rel="up" href="../hash.html" title="Chapter 16. Boost.Functional/Hash">
10 <link rel="prev" href="disable.html" title="Disabling The Extensions">
11 <link rel="next" href="rationale.html" title="Rationale">
13 <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
14 <table cellpadding="2" width="100%"><tr>
15 <td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../boost.png"></td>
16 <td align="center"><a href="../../../index.html">Home</a></td>
17 <td align="center"><a href="../../../libs/libraries.htm">Libraries</a></td>
18 <td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
19 <td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
20 <td align="center"><a href="../../../more/index.htm">More</a></td>
23 <div class="spirit-nav">
24 <a accesskey="p" href="disable.html"><img src="../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../hash.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="rationale.html"><img src="../../../doc/src/images/next.png" alt="Next"></a>
27 <div class="titlepage"><div><div><h2 class="title" style="clear: both">
28 <a name="hash.changes"></a><a class="link" href="changes.html" title="Change Log">Change Log</a>
29 </h2></div></div></div>
31 <a name="hash.changes.h0"></a>
32 <span class="phrase"><a name="hash.changes.boost_1_33_0"></a></span><a class="link" href="changes.html#hash.changes.boost_1_33_0">Boost
35 <div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; "><li class="listitem">
39 <a name="hash.changes.h1"></a>
40 <span class="phrase"><a name="hash.changes.boost_1_33_1"></a></span><a class="link" href="changes.html#hash.changes.boost_1_33_1">Boost
43 <div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; "><li class="listitem">
44 Fixed the points example, as pointed out by 沈慧峰.
47 <a name="hash.changes.h2"></a>
48 <span class="phrase"><a name="hash.changes.boost_1_34_0"></a></span><a class="link" href="changes.html#hash.changes.boost_1_34_0">Boost
51 <div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; ">
53 Use declarations for standard classes, so that the library doesn't need
54 to include all of their headers
57 Deprecated the <code class="computeroutput"><span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">functional</span><span class="special">/</span><span class="identifier">hash</span><span class="comment">/*.hpp></span></code> headers. Now a single header,
58 <<code class="computeroutput"><a class="link" href="reference.html#header.boost.functional.hash_hpp" title="Header <boost/functional/hash.hpp>">boost/functional/hash.hpp</a></code>>
62 Add support for the <code class="computeroutput"><span class="identifier">BOOST_HASH_NO_EXTENSIONS</span></code>
63 macro, which disables the extensions to TR1.
66 Minor improvements to the hash functions for floating point numbers.
69 Update the portable example to hopefully be more generally portable.
73 <a name="hash.changes.h3"></a>
74 <span class="phrase"><a name="hash.changes.boost_1_34_1"></a></span><a class="link" href="changes.html#hash.changes.boost_1_34_1">Boost
77 <div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; "><li class="listitem">
78 <a href="http://svn.boost.org/trac/boost/ticket/952" target="_top">Ticket 952</a>:
79 Suppress incorrect 64-bit warning on Visual C++.
82 <a name="hash.changes.h4"></a>
83 <span class="phrase"><a name="hash.changes.boost_1_35_0"></a></span><a class="link" href="changes.html#hash.changes.boost_1_35_0">Boost
86 <div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; ">
88 Support for <code class="computeroutput"><span class="keyword">long</span> <span class="keyword">long</span></code>,
89 <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">complex</span></code>.
92 Improved algorithm for hashing floating point numbers:
93 <div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: circle; ">
95 Improved portablity, as described by Daniel Krügler in <a href="http://lists.boost.org/boost-users/2005/08/13418.php" target="_top">a
96 post to the boost users list</a>.
99 Fits more information into each combine loop, which can reduce the
100 the number of times combine is called and hopefully give a better
101 quality hash function.
103 <li class="listitem">
104 Improved the algorithm for hashing floating point numbers.
106 <li class="listitem">
107 On Cygwin use a binary hash function for floating point numbers,
108 as Cygwin doesn't have decent floating point functions for <code class="computeroutput"><span class="keyword">long</span> <span class="keyword">double</span></code>.
110 <li class="listitem">
111 Never uses <code class="computeroutput"><span class="identifier">fpclass</span></code>
112 which doesn't support <code class="computeroutput"><span class="keyword">long</span>
113 <span class="keyword">double</span></code>.
115 <li class="listitem">
116 <a href="http://svn.boost.org/trac/boost/ticket/1064" target="_top">Ticket 1064</a>:
117 Removed unnecessary use of <code class="computeroutput"><span class="identifier">errno</span></code>.
121 <li class="listitem">
122 Explicitly overload for more built in types.
124 <li class="listitem">
125 Minor improvements to the documentation.
127 <li class="listitem">
128 A few bug and warning fixes:
129 <div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: circle; ">
130 <li class="listitem">
131 <a href="http://svn.boost.org/trac/boost/ticket/1509" target="_top">Ticket 1509</a>:
132 Suppress another Visual C++ warning.
134 <li class="listitem">
135 Some workarounds for the Sun compilers.
141 <a name="hash.changes.h5"></a>
142 <span class="phrase"><a name="hash.changes.boost_1_36_0"></a></span><a class="link" href="changes.html#hash.changes.boost_1_36_0">Boost
145 <div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; ">
146 <li class="listitem">
147 Stop using OpenBSD's dodgy <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">numeric_limits</span></code>.
149 <li class="listitem">
150 Using the boost typedefs for <code class="computeroutput"><span class="keyword">long</span>
151 <span class="keyword">long</span></code> and <code class="computeroutput"><span class="keyword">unsigned</span>
152 <span class="keyword">long</span> <span class="keyword">long</span></code>.
154 <li class="listitem">
155 Move the extensions into their own header.
159 <a name="hash.changes.h6"></a>
160 <span class="phrase"><a name="hash.changes.boost_1_37_0"></a></span><a class="link" href="changes.html#hash.changes.boost_1_37_0">Boost
163 <div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; "><li class="listitem">
164 <a href="http://svn.boost.org/trac/boost/ticket/2264" target="_top">Ticket 2264</a>:
165 In Visual C++, always use C99 float functions for <code class="computeroutput"><span class="keyword">long</span>
166 <span class="keyword">double</span></code> and <code class="computeroutput"><span class="keyword">float</span></code>
167 as the C++ overloads aren't always availables.
170 <a name="hash.changes.h7"></a>
171 <span class="phrase"><a name="hash.changes.boost_1_38_0"></a></span><a class="link" href="changes.html#hash.changes.boost_1_38_0">Boost
174 <div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; ">
175 <li class="listitem">
176 Changed the warnings in the deprecated headers from 1.34.0 to errors. These
177 will be removed in a future version of Boost.
179 <li class="listitem">
180 Moved detail headers out of <code class="computeroutput"><span class="identifier">boost</span><span class="special">/</span><span class="identifier">functional</span><span class="special">/</span><span class="identifier">detail</span></code>,
181 since they are part of functional/hash, not functional. <code class="computeroutput"><span class="identifier">boost</span><span class="special">/</span><span class="identifier">functional</span><span class="special">/</span><span class="identifier">detail</span><span class="special">/</span><span class="identifier">container_fwd</span><span class="special">.</span><span class="identifier">hpp</span></code>
182 has been moved to <code class="computeroutput"><span class="identifier">boost</span><span class="special">/</span><span class="identifier">detail</span><span class="special">/</span><span class="identifier">container_fwd</span><span class="special">.</span><span class="identifier">hpp</span></code>
183 as it's used outside of this library, the others have been moved to <code class="computeroutput"><span class="identifier">boost</span><span class="special">/</span><span class="identifier">functional</span><span class="special">/</span><span class="identifier">hash</span><span class="special">/</span><span class="identifier">detail</span></code>.
187 <a name="hash.changes.h8"></a>
188 <span class="phrase"><a name="hash.changes.boost_1_39_0"></a></span><a class="link" href="changes.html#hash.changes.boost_1_39_0">Boost
191 <div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; ">
192 <li class="listitem">
193 Move the hash_fwd.hpp implementation into the hash subdirectory, leaving
194 a forwarding header in the old location. You should still use the old location,
195 the new location is mainly for implementation and possible modularization.
197 <li class="listitem">
198 <a href="https://svn.boost.org/trac/boost/ticket/2412" target="_top">Ticket 2412</a>:
199 Removed deprecated headers.
201 <li class="listitem">
202 <a href="https://svn.boost.org/trac/boost/ticket/2957" target="_top">Ticket 2957</a>:
203 Fix configuration for vxworks.
207 <a name="hash.changes.h9"></a>
208 <span class="phrase"><a name="hash.changes.boost_1_40_0"></a></span><a class="link" href="changes.html#hash.changes.boost_1_40_0">Boost
211 <div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; ">
212 <li class="listitem">
213 Automatically configure the float functions using template metaprogramming
214 instead of trying to configure every possibility manually.
216 <li class="listitem">
217 Workaround for when STLport doesn't support long double.
221 <a name="hash.changes.h10"></a>
222 <span class="phrase"><a name="hash.changes.boost_1_42_0"></a></span><a class="link" href="changes.html#hash.changes.boost_1_42_0">Boost
225 <div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; ">
226 <li class="listitem">
227 Reduce the number of warnings for Visual C++ warning level 4.
229 <li class="listitem">
230 Some code formatting changes to fit lines into 80 characters.
232 <li class="listitem">
233 Rename an internal namespace.
237 <a name="hash.changes.h11"></a>
238 <span class="phrase"><a name="hash.changes.boost_1_43_0"></a></span><a class="link" href="changes.html#hash.changes.boost_1_43_0">Boost
241 <div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; ">
242 <li class="listitem">
243 <a href="https://svn.boost.org/trac/boost/ticket/3866" target="_top">Ticket 3866</a>:
244 Don't foward declare containers when using gcc's parallel library, allow
245 user to stop forward declaration by defining the <code class="computeroutput"><span class="identifier">BOOST_DETAIL_NO_CONTAINER_FWD</span></code>
248 <li class="listitem">
249 <a href="https://svn.boost.org/trac/boost/ticket/4038" target="_top">Ticket 4038</a>:
250 Avoid hashing 0.5 and 0 to the same number.
252 <li class="listitem">
253 Stop using deprecated <code class="computeroutput"><span class="identifier">BOOST_HAS_</span><span class="special">*</span></code> macros.
257 <a name="hash.changes.h12"></a>
258 <span class="phrase"><a name="hash.changes.boost_1_44_0"></a></span><a class="link" href="changes.html#hash.changes.boost_1_44_0">Boost
261 <div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; "><li class="listitem">
262 Add option to prevent implicit conversions when calling <code class="computeroutput"><span class="identifier">hash_value</span></code>
263 by defining <code class="computeroutput"><span class="identifier">BOOST_HASH_NO_IMPLICIT_CASTS</span></code>.
264 When using <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">hash</span></code> for a type that does not have <code class="computeroutput"><span class="identifier">hash_value</span></code> declared but does have an
265 implicit conversion to a type that does, it would use that implicit conversion
266 to hash it. Which can sometimes go very wrong, e.g. using a conversion
267 to bool and only hashing to 2 possible values. Since fixing this is a breaking
268 change and was only approached quite late in the release cycle with little
269 discussion it's opt-in for now. This, or something like it, will become
270 the default in a future version.
273 <a name="hash.changes.h13"></a>
274 <span class="phrase"><a name="hash.changes.boost_1_46_0"></a></span><a class="link" href="changes.html#hash.changes.boost_1_46_0">Boost
277 <div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; "><li class="listitem">
278 Avoid warning due with gcc's <code class="computeroutput"><span class="special">-</span><span class="identifier">Wconversion</span></code> flag.
281 <a name="hash.changes.h14"></a>
282 <span class="phrase"><a name="hash.changes.boost_1_50_0"></a></span><a class="link" href="changes.html#hash.changes.boost_1_50_0">Boost
285 <div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; ">
286 <li class="listitem">
287 <a href="http://svn.boost.org/trac/boost/ticket/6771" target="_top">Ticket 6771</a>:
288 Avoid gcc's <code class="computeroutput"><span class="special">-</span><span class="identifier">Wfloat</span><span class="special">-</span><span class="identifier">equal</span></code>
291 <li class="listitem">
292 <a href="http://svn.boost.org/trac/boost/ticket/6806" target="_top">Ticket 6806</a>:
293 Support <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">array</span></code> and <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">tuple</span></code>
296 <li class="listitem">
297 Add deprecation warning to the long deprecated <code class="computeroutput"><span class="identifier">boost</span><span class="special">/</span><span class="identifier">functional</span><span class="special">/</span><span class="identifier">detail</span><span class="special">/</span><span class="identifier">container_fwd</span><span class="special">.</span><span class="identifier">hpp</span></code>.
301 <a name="hash.changes.h15"></a>
302 <span class="phrase"><a name="hash.changes.boost_1_51_0"></a></span><a class="link" href="changes.html#hash.changes.boost_1_51_0">Boost
305 <div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; ">
306 <li class="listitem">
307 Support the standard smart pointers.
309 <li class="listitem">
310 <code class="computeroutput"><span class="identifier">hash_value</span></code> now implemented
311 using SFINAE to avoid implicit casts to built in types when calling it.
313 <li class="listitem">
314 Updated to use the new config macros.
318 <a name="hash.changes.h16"></a>
319 <span class="phrase"><a name="hash.changes.boost_1_52_0"></a></span><a class="link" href="changes.html#hash.changes.boost_1_52_0">Boost
322 <div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; ">
323 <li class="listitem">
324 Restore <code class="computeroutput"><span class="keyword">enum</span></code> support, which
325 was accidentally removed in the last version.
327 <li class="listitem">
328 New floating point hasher - will hash the binary representation on more
329 platforms, which should be faster.
333 <a name="hash.changes.h17"></a>
334 <span class="phrase"><a name="hash.changes.boost_1_53_0"></a></span><a class="link" href="changes.html#hash.changes.boost_1_53_0">Boost
337 <div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; ">
338 <li class="listitem">
339 Add support for <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">int128_type</span></code> and <code class="computeroutput"><span class="identifier">boost</span><span class="special">::</span><span class="identifier">uint128_type</span></code>
340 where available - currently only <code class="computeroutput"><span class="identifier">__int128</span></code>
341 and <code class="computeroutput"><span class="keyword">unsigned</span> <span class="identifier">__int128</span></code>
342 on some versions of gcc.
344 <li class="listitem">
345 On platforms that are known to have the standard floating point functions,
346 don't use automatic detection - which can break if there are ambiguous
349 <li class="listitem">
350 Fix undefined behaviour when using the binary float hash (Thomas Heller).
354 <a name="hash.changes.h18"></a>
355 <span class="phrase"><a name="hash.changes.boost_1_54_0"></a></span><a class="link" href="changes.html#hash.changes.boost_1_54_0">Boost
358 <div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; "><li class="listitem">
359 <a href="https://svn.boost.org/trac/boost/ticket/7957" target="_top">Ticket 7957</a>:
363 <a name="hash.changes.h19"></a>
364 <span class="phrase"><a name="hash.changes.boost_1_55_0"></a></span><a class="link" href="changes.html#hash.changes.boost_1_55_0">Boost
367 <div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; ">
368 <li class="listitem">
369 Simplify a SFINAE check so that it will hopefully work on Sun 5.9 (<a href="https://svn.boost.org/trac/boost/ticket/8822" target="_top">#8822</a>).
371 <li class="listitem">
372 Suppress Visual C++ infinite loop warning (<a href="https://svn.boost.org/trac/boost/ticket/8568" target="_top">#8568</a>).
376 <a name="hash.changes.h20"></a>
377 <span class="phrase"><a name="hash.changes.boost_1_56_0"></a></span><a class="link" href="changes.html#hash.changes.boost_1_56_0">Boost
380 <div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; ">
381 <li class="listitem">
382 Removed some Visual C++ 6 workarounds.
384 <li class="listitem">
385 Ongoing work on improving <code class="computeroutput"><span class="identifier">hash_combine</span></code>.
386 This changes the combine function which was previously defined in the reference
391 <a name="hash.changes.h21"></a>
392 <span class="phrase"><a name="hash.changes.boost_1_58_0"></a></span><a class="link" href="changes.html#hash.changes.boost_1_58_0">Boost
395 <div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; "><li class="listitem">
396 Fixed strict aliasing violation (<a href="https://github.com/boostorg/functional/pull/3" target="_top">GitHub
400 <a name="hash.changes.h22"></a>
401 <span class="phrase"><a name="hash.changes.boost_1_63_0"></a></span><a class="link" href="changes.html#hash.changes.boost_1_63_0">Boost
404 <div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; ">
405 <li class="listitem">
408 <li class="listitem">
409 Only define hash for <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">wstring</span></code>
410 when we know we have a <code class="computeroutput"><span class="keyword">wchar_t</span></code>.
411 Otherwise there's a compile error as there's no overload for hashing the
412 characters in wide strings (<a href="https://svn.boost.org/trac/boost/ticket/8552" target="_top">#8552</a>).
416 <a name="hash.changes.h23"></a>
417 <span class="phrase"><a name="hash.changes.boost_1_64_0"></a></span><a class="link" href="changes.html#hash.changes.boost_1_64_0">Boost
420 <div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; "><li class="listitem">
421 Fix for recent versions of Visual C++ which have removed <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">unary_function</span></code> and <code class="computeroutput"><span class="identifier">std</span><span class="special">::</span><span class="identifier">binary_function</span></code>.
424 <table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
425 <td align="left"></td>
426 <td align="right"><div class="copyright-footer">Copyright © 2005-2008 Daniel
428 Distributed under the Boost Software License, Version 1.0. (See accompanying
429 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>)
434 <div class="spirit-nav">
435 <a accesskey="p" href="disable.html"><img src="../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../hash.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="rationale.html"><img src="../../../doc/src/images/next.png" alt="Next"></a>