structboost_1_1hana_1_1set.html 65 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526
  1. <!--
  2. Copyright Louis Dionne 2013-2017
  3. Distributed under the Boost Software License, Version 1.0.
  4. (See accompanying file LICENSE.md or copy at http://boost.org/LICENSE_1_0.txt)
  5. -->
  6. <!-- boost-no-inspect -->
  7. <!-- HTML header for doxygen 1.8.9.1-->
  8. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  9. <html xmlns="http://www.w3.org/1999/xhtml">
  10. <head>
  11. <meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
  12. <meta http-equiv="X-UA-Compatible" content="IE=9"/>
  13. <meta name="generator" content="Doxygen 1.8.15"/>
  14. <title>Boost.Hana: boost::hana::set&lt; implementation_defined &gt; Struct Template Reference</title>
  15. <link href="tabs.css" rel="stylesheet" type="text/css"/>
  16. <script type="text/javascript" src="jquery.js"></script>
  17. <script type="text/javascript" src="dynsections.js"></script>
  18. <link href="navtree.css" rel="stylesheet" type="text/css"/>
  19. <script type="text/javascript" src="resize.js"></script>
  20. <script type="text/javascript" src="navtreedata.js"></script>
  21. <script type="text/javascript" src="navtree.js"></script>
  22. <script type="text/javascript">
  23. /* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
  24. $(document).ready(initResizable);
  25. /* @license-end */</script>
  26. <link href="search/search.css" rel="stylesheet" type="text/css"/>
  27. <script type="text/javascript" src="search/searchdata.js"></script>
  28. <script type="text/javascript" src="search/search.js"></script>
  29. <script type="text/javascript">
  30. /* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
  31. $(document).ready(function() { init_search(); });
  32. /* @license-end */
  33. </script>
  34. <script type="text/x-mathjax-config">
  35. MathJax.Hub.Config({
  36. extensions: ["tex2jax.js"],
  37. jax: ["input/TeX","output/HTML-CSS"],
  38. });
  39. // Copyright Louis Dionne 2013-2017
  40. // Distributed under the Boost Software License, Version 1.0.
  41. // (See accompanying file LICENSE.md or copy at http://boost.org/LICENSE_1_0.txt)
  42. MathJax.Hub.Config({
  43. "HTML-CSS": {
  44. linebreaks: {
  45. automatic: true,
  46. width: "75% container"
  47. }
  48. }
  49. });
  50. </script><script type="text/javascript" async="async" src="https://cdn.mathjax.org/mathjax/latest/MathJax.js"></script>
  51. <link href="doxygen.css" rel="stylesheet" type="text/css" />
  52. <!-- Additional javascript for drawing charts. -->
  53. <script type="text/javascript" src="highcharts.js"></script>
  54. <script type="text/javascript" src="highcharts-data.js"></script>
  55. <script type="text/javascript" src="highcharts-exporting.js"></script>
  56. <script type="text/javascript" src="chart.js"></script>
  57. <script type="text/javascript" src="hana.js"></script>
  58. </head>
  59. <body>
  60. <div id="top"><!-- do not remove this div, it is closed by doxygen! -->
  61. <div id="titlearea">
  62. <table cellspacing="0" cellpadding="0">
  63. <tbody>
  64. <tr style="height: 56px;">
  65. <td id="projectlogo"><img alt="Logo" src="Boost.png"/></td>
  66. <td style="padding-left: 0.5em;">
  67. <div id="projectname">Boost.Hana
  68. &#160;<span id="projectnumber">1.6.0</span>
  69. </div>
  70. <div id="projectbrief">Your standard library for metaprogramming</div>
  71. </td>
  72. <td> <div id="MSearchBox" class="MSearchBoxInactive">
  73. <span class="left">
  74. <img id="MSearchSelect" src="search/mag_sel.png"
  75. onmouseover="return searchBox.OnSearchSelectShow()"
  76. onmouseout="return searchBox.OnSearchSelectHide()"
  77. alt=""/>
  78. <input type="text" id="MSearchField" value="Search" accesskey="S"
  79. onfocus="searchBox.OnSearchFieldFocus(true)"
  80. onblur="searchBox.OnSearchFieldFocus(false)"
  81. onkeyup="searchBox.OnSearchFieldChange(event)"/>
  82. </span><span class="right">
  83. <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a>
  84. </span>
  85. </div>
  86. </td>
  87. </tr>
  88. </tbody>
  89. </table>
  90. </div>
  91. <!-- end header part -->
  92. <!-- Generated by Doxygen 1.8.15 -->
  93. <script type="text/javascript">
  94. /* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
  95. var searchBox = new SearchBox("searchBox", "search",false,'Search');
  96. /* @license-end */
  97. </script>
  98. </div><!-- top -->
  99. <div id="side-nav" class="ui-resizable side-nav-resizable">
  100. <div id="nav-tree">
  101. <div id="nav-tree-contents">
  102. <div id="nav-sync" class="sync"></div>
  103. </div>
  104. </div>
  105. <div id="splitbar" style="-moz-user-select:none;"
  106. class="ui-resizable-handle">
  107. </div>
  108. </div>
  109. <script type="text/javascript">
  110. /* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
  111. $(document).ready(function(){initNavTree('structboost_1_1hana_1_1set.html','');});
  112. /* @license-end */
  113. </script>
  114. <div id="doc-content">
  115. <!-- window showing the filter options -->
  116. <div id="MSearchSelectWindow"
  117. onmouseover="return searchBox.OnSearchSelectShow()"
  118. onmouseout="return searchBox.OnSearchSelectHide()"
  119. onkeydown="return searchBox.OnSearchSelectKey(event)">
  120. </div>
  121. <!-- iframe showing the search results (closed by default) -->
  122. <div id="MSearchResultsWindow">
  123. <iframe src="javascript:void(0)" frameborder="0"
  124. name="MSearchResults" id="MSearchResults">
  125. </iframe>
  126. </div>
  127. <div class="header">
  128. <div class="summary">
  129. <a href="#related">Synopsis of associated functions</a> &#124;
  130. <a href="#friends">Friends</a> &#124;
  131. <a href="#pub-methods">Public Member Functions</a> &#124;
  132. <a href="structboost_1_1hana_1_1set-members.html">List of all members</a> </div>
  133. <div class="headertitle">
  134. <div class="title">boost::hana::set&lt; implementation_defined &gt; Struct Template Reference<div class="ingroups"><a class="el" href="group__group-datatypes.html">Data types</a></div></div> </div>
  135. </div><!--header-->
  136. <div class="contents">
  137. <a name="details" id="details"></a><h2 class="groupheader">Description</h2>
  138. <div class="textblock"><h3>template&lt;typename implementation_defined&gt;<br />
  139. struct boost::hana::set&lt; implementation_defined &gt;</h3>
  140. <p>Basic unordered container requiring unique, <code>Comparable</code> and <code>Hashable</code> keys. </p>
  141. <p>A set is an unordered container that can hold heterogeneous keys. A set requires (and ensures) that no duplicates are present when inserting new keys.</p>
  142. <dl class="section note"><dt>Note</dt><dd>The actual representation of a <code><a class="el" href="structboost_1_1hana_1_1set.html" title="Basic unordered container requiring unique, Comparable and Hashable keys.">hana::set</a></code> is implementation-defined. In particular, one should not take for granted the order of the template parameters and the presence of any additional constructors or assignment operators than what is documented. The canonical way of creating a <code><a class="el" href="structboost_1_1hana_1_1set.html" title="Basic unordered container requiring unique, Comparable and Hashable keys.">hana::set</a></code> is through <code>hana::make_set</code>. More details <a class="el" href="index.html#tutorial-containers-types">in the tutorial</a>.</dd></dl>
  143. <h2>Modeled concepts </h2>
  144. <ol type="1">
  145. <li><code>Comparable</code><br />
  146. Two sets are equal iff they contain the same elements, regardless of the order. <div class="fragment"><div class="line"><span class="comment">// Copyright Louis Dionne 2013-2017</span></div><div class="line"><span class="comment">// Distributed under the Boost Software License, Version 1.0.</span></div><div class="line"><span class="comment">// (See accompanying file LICENSE.md or copy at http://boost.org/LICENSE_1_0.txt)</span></div><div class="line"></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="assert_8hpp.html">boost/hana/assert.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="equal_8hpp.html">boost/hana/equal.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="integral__constant_8hpp.html">boost/hana/integral_constant.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="not__equal_8hpp.html">boost/hana/not_equal.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="set_8hpp.html">boost/hana/set.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="type_8hpp.html">boost/hana/type.hpp</a>&gt;</span></div><div class="line"><span class="keyword">namespace </span>hana = <a class="code" href="namespaceboost_1_1hana.html">boost::hana</a>;</div><div class="line"></div><div class="line"></div><div class="line"><span class="keywordtype">int</span> main() {</div><div class="line"> <a class="code" href="group__group-assertions.html#ga2c5006540936d9f8880e3a39f4fcc035">BOOST_HANA_CONSTANT_CHECK</a>(</div><div class="line"> hana::make_set(hana::int_c&lt;0&gt;, hana::type_c&lt;char&gt;, hana::int_c&lt;1&gt;)</div><div class="line"> ==</div><div class="line"> hana::make_set(hana::int_c&lt;1&gt;, hana::int_c&lt;0&gt;, hana::type_c&lt;char&gt;)</div><div class="line"> );</div><div class="line"></div><div class="line"> <a class="code" href="group__group-assertions.html#ga2c5006540936d9f8880e3a39f4fcc035">BOOST_HANA_CONSTANT_CHECK</a>(</div><div class="line"> hana::make_set(hana::int_c&lt;0&gt;, hana::type_c&lt;char&gt;)</div><div class="line"> !=</div><div class="line"> hana::make_set(hana::int_c&lt;1&gt;)</div><div class="line"> );</div><div class="line">}</div></div><!-- fragment --></li>
  147. <li>Foldable<br />
  148. Folding a set is equivalent to folding the sequence of its values. However, note that the values are not required to be in any specific order, so using the folds provided here with an operation that is not both commutative and associative will yield non-deterministic behavior. <div class="fragment"><div class="line"><span class="comment">// Copyright Louis Dionne 2013-2017</span></div><div class="line"><span class="comment">// Distributed under the Boost Software License, Version 1.0.</span></div><div class="line"><span class="comment">// (See accompanying file LICENSE.md or copy at http://boost.org/LICENSE_1_0.txt)</span></div><div class="line"></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="assert_8hpp.html">boost/hana/assert.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="equal_8hpp.html">boost/hana/equal.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="integral__constant_8hpp.html">boost/hana/integral_constant.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="maximum_8hpp.html">boost/hana/maximum.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="minimum_8hpp.html">boost/hana/minimum.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="set_8hpp.html">boost/hana/set.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="sum_8hpp.html">boost/hana/sum.hpp</a>&gt;</span></div><div class="line"><span class="keyword">namespace </span>hana = <a class="code" href="namespaceboost_1_1hana.html">boost::hana</a>;</div><div class="line"></div><div class="line"></div><div class="line"><span class="keywordtype">int</span> main() {</div><div class="line"> constexpr <span class="keyword">auto</span> xs = hana::make_set(hana::int_c&lt;0&gt;, hana::int_c&lt;1&gt;, hana::int_c&lt;2&gt;);</div><div class="line"> static_assert(<a class="code" href="group__group-Foldable.html#ga347429451fdb15f9f7a7fc0de293be1a">hana::minimum</a>(xs) == hana::int_c&lt;0&gt;, <span class="stringliteral">&quot;&quot;</span>);</div><div class="line"> static_assert(<a class="code" href="group__group-Foldable.html#gaf3861a91607203b63a12708e18a4eac5">hana::maximum</a>(xs) == hana::int_c&lt;2&gt;, <span class="stringliteral">&quot;&quot;</span>);</div><div class="line"> static_assert(hana::sum&lt;&gt;(xs) == hana::int_c&lt;3&gt;, <span class="stringliteral">&quot;&quot;</span>);</div><div class="line">}</div></div><!-- fragment --></li>
  149. <li>Searchable<br />
  150. The elements in a set act as both its keys and its values. Since the elements of a set are unique, searching for an element will return either the only element which is equal to the searched value, or <code>nothing</code>. Also note that <code>operator[]</code> can be used instead of the <code>at_key</code> function. <div class="fragment"><div class="line"><span class="comment">// Copyright Louis Dionne 2013-2017</span></div><div class="line"><span class="comment">// Distributed under the Boost Software License, Version 1.0.</span></div><div class="line"><span class="comment">// (See accompanying file LICENSE.md or copy at http://boost.org/LICENSE_1_0.txt)</span></div><div class="line"></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="assert_8hpp.html">boost/hana/assert.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="at__key_8hpp.html">boost/hana/at_key.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="equal_8hpp.html">boost/hana/equal.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="find_8hpp.html">boost/hana/find.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="integral__constant_8hpp.html">boost/hana/integral_constant.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="optional_8hpp.html">boost/hana/optional.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="set_8hpp.html">boost/hana/set.hpp</a>&gt;</span></div><div class="line"><span class="keyword">namespace </span>hana = <a class="code" href="namespaceboost_1_1hana.html">boost::hana</a>;</div><div class="line"></div><div class="line"></div><div class="line"><span class="keywordtype">int</span> main() {</div><div class="line"> constexpr <span class="keyword">auto</span> xs = hana::make_set(hana::int_c&lt;0&gt;, hana::int_c&lt;1&gt;, hana::int_c&lt;2&gt;);</div><div class="line"> <a class="code" href="group__group-assertions.html#ga2c5006540936d9f8880e3a39f4fcc035">BOOST_HANA_CONSTANT_CHECK</a>(<a class="code" href="group__group-Searchable.html#ga6b6cdd69942b0fe3bf5254247f9c861e">hana::find</a>(xs, hana::int_c&lt;0&gt;) == hana::just(hana::int_c&lt;0&gt;));</div><div class="line"> <a class="code" href="group__group-assertions.html#ga2c5006540936d9f8880e3a39f4fcc035">BOOST_HANA_CONSTANT_CHECK</a>(<a class="code" href="group__group-Searchable.html#ga6b6cdd69942b0fe3bf5254247f9c861e">hana::find</a>(xs, hana::int_c&lt;3&gt;) == hana::nothing);</div><div class="line"></div><div class="line"> <span class="comment">// operator[] is equivalent to at_key</span></div><div class="line"> <a class="code" href="group__group-assertions.html#ga2c5006540936d9f8880e3a39f4fcc035">BOOST_HANA_CONSTANT_CHECK</a>(xs[hana::int_c&lt;2&gt;] == hana::int_c&lt;2&gt;);</div><div class="line"></div><div class="line"> <span class="comment">// long_c&lt;0&gt; == int_&lt;0&gt;, and therefore int_&lt;0&gt; is found</span></div><div class="line"> <a class="code" href="group__group-assertions.html#ga2c5006540936d9f8880e3a39f4fcc035">BOOST_HANA_CONSTANT_CHECK</a>(xs[hana::long_c&lt;0&gt;] == hana::int_c&lt;0&gt;);</div><div class="line">}</div></div><!-- fragment --></li>
  151. </ol>
  152. <h2>Conversion from any <code>Foldable</code> </h2>
  153. <p>Any <code>Foldable</code> structure can be converted into a <code><a class="el" href="structboost_1_1hana_1_1set.html" title="Basic unordered container requiring unique, Comparable and Hashable keys.">hana::set</a></code> with <code>to&lt;<a class="el" href="structboost_1_1hana_1_1set__tag.html" title="Tag representing the hana::set container.">set_tag</a>&gt;</code>. The elements of the structure must all be compile-time <code>Comparable</code>. If the structure contains duplicate elements, only the first occurence will appear in the resulting set. More specifically, conversion from a <code>Foldable</code> is equivalent to </p><div class="fragment"><div class="line">to&lt;set_tag&gt;(xs) == <a class="code" href="group__group-Foldable.html#ga38c6b3f6b1cbadb9b8432a05ff16b7d2">fold_left</a>(xs, <a class="code" href="structboost_1_1hana_1_1set.html#af38c23fb98d8eec68c1491a8bca9ce43">make_set</a>(), <a class="code" href="structboost_1_1hana_1_1set.html#a5791e6dc0e27d8e3a113e4d94482550f">insert</a>)</div></div><!-- fragment --><p><b>Example</b> </p><div class="fragment"><div class="line"><span class="comment">// Copyright Louis Dionne 2013-2017</span></div><div class="line"><span class="comment">// Distributed under the Boost Software License, Version 1.0.</span></div><div class="line"><span class="comment">// (See accompanying file LICENSE.md or copy at http://boost.org/LICENSE_1_0.txt)</span></div><div class="line"></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="assert_8hpp.html">boost/hana/assert.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="core_2to_8hpp.html">boost/hana/core/to.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="equal_8hpp.html">boost/hana/equal.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="integral__constant_8hpp.html">boost/hana/integral_constant.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="set_8hpp.html">boost/hana/set.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="tuple_8hpp.html">boost/hana/tuple.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="type_8hpp.html">boost/hana/type.hpp</a>&gt;</span></div><div class="line"><span class="keyword">namespace </span>hana = <a class="code" href="namespaceboost_1_1hana.html">boost::hana</a>;</div><div class="line"></div><div class="line"></div><div class="line"><span class="keywordtype">int</span> main() {</div><div class="line"> constexpr <span class="keyword">auto</span> xs = hana::make_tuple(</div><div class="line"> hana::int_c&lt;1&gt;,</div><div class="line"> hana::int_c&lt;3&gt;,</div><div class="line"> hana::type_c&lt;int&gt;,</div><div class="line"> hana::long_c&lt;1&gt;</div><div class="line"> );</div><div class="line"></div><div class="line"> <a class="code" href="group__group-assertions.html#ga2c5006540936d9f8880e3a39f4fcc035">BOOST_HANA_CONSTANT_CHECK</a>(</div><div class="line"> hana::to&lt;hana::set_tag&gt;(xs)</div><div class="line"> ==</div><div class="line"> hana::make_set(hana::int_c&lt;1&gt;, hana::int_c&lt;3&gt;, hana::type_c&lt;int&gt;)</div><div class="line"> );</div><div class="line">}</div></div><!-- fragment --> </div><table class="memberdecls">
  154. <tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="related"></a>
  155. Synopsis of associated functions</h2></td></tr>
  156. <tr class="memitem:aa337857e80b8a8c91880b0184aaf7534"><td class="memTemplParams" colspan="2">template&lt;&gt; </td></tr>
  157. <tr class="memitem:aa337857e80b8a8c91880b0184aaf7534"><td class="memTemplItemLeft" align="right" valign="top">constexpr auto&#160;</td><td class="memTemplItemRight" valign="bottom"><a class="el" href="structboost_1_1hana_1_1set.html#aa337857e80b8a8c91880b0184aaf7534">make&lt; set_tag &gt;</a></td></tr>
  158. <tr class="memdesc:aa337857e80b8a8c91880b0184aaf7534"><td class="mdescLeft">&#160;</td><td class="mdescRight">Function object for creating a <code><a class="el" href="structboost_1_1hana_1_1set.html" title="Basic unordered container requiring unique, Comparable and Hashable keys.">hana::set</a></code>. <a href="#aa337857e80b8a8c91880b0184aaf7534">More...</a><br /></td></tr>
  159. <tr class="separator:aa337857e80b8a8c91880b0184aaf7534"><td class="memSeparator" colspan="2">&#160;</td></tr>
  160. <tr class="memitem:af38c23fb98d8eec68c1491a8bca9ce43"><td class="memItemLeft" align="right" valign="top">constexpr auto&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structboost_1_1hana_1_1set.html#af38c23fb98d8eec68c1491a8bca9ce43">make_set</a> = <a class="el" href="group__group-core.html#ga1d92480f0af1029878e773dafa3e2f60">make</a>&lt;<a class="el" href="structboost_1_1hana_1_1set__tag.html">set_tag</a>&gt;</td></tr>
  161. <tr class="memdesc:af38c23fb98d8eec68c1491a8bca9ce43"><td class="mdescLeft">&#160;</td><td class="mdescRight">Equivalent to <code>make&lt;<a class="el" href="structboost_1_1hana_1_1set__tag.html" title="Tag representing the hana::set container.">set_tag</a>&gt;</code>; provided for convenience. <a href="#af38c23fb98d8eec68c1491a8bca9ce43">More...</a><br /></td></tr>
  162. <tr class="separator:af38c23fb98d8eec68c1491a8bca9ce43"><td class="memSeparator" colspan="2">&#160;</td></tr>
  163. <tr class="memitem:a5791e6dc0e27d8e3a113e4d94482550f"><td class="memItemLeft" align="right" valign="top">constexpr auto&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structboost_1_1hana_1_1set.html#a5791e6dc0e27d8e3a113e4d94482550f">insert</a></td></tr>
  164. <tr class="memdesc:a5791e6dc0e27d8e3a113e4d94482550f"><td class="mdescLeft">&#160;</td><td class="mdescRight">Insert an element in a <code><a class="el" href="structboost_1_1hana_1_1set.html" title="Basic unordered container requiring unique, Comparable and Hashable keys.">hana::set</a></code>. <a href="#a5791e6dc0e27d8e3a113e4d94482550f">More...</a><br /></td></tr>
  165. <tr class="separator:a5791e6dc0e27d8e3a113e4d94482550f"><td class="memSeparator" colspan="2">&#160;</td></tr>
  166. <tr class="memitem:af856f7bf77f69cdf1b8fd4e566eaef9b"><td class="memItemLeft" align="right" valign="top">constexpr auto&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structboost_1_1hana_1_1set.html#af856f7bf77f69cdf1b8fd4e566eaef9b">erase_key</a></td></tr>
  167. <tr class="memdesc:af856f7bf77f69cdf1b8fd4e566eaef9b"><td class="mdescLeft">&#160;</td><td class="mdescRight">Remove an element from a <code><a class="el" href="structboost_1_1hana_1_1set.html" title="Basic unordered container requiring unique, Comparable and Hashable keys.">hana::set</a></code>. <a href="#af856f7bf77f69cdf1b8fd4e566eaef9b">More...</a><br /></td></tr>
  168. <tr class="separator:af856f7bf77f69cdf1b8fd4e566eaef9b"><td class="memSeparator" colspan="2">&#160;</td></tr>
  169. <tr class="memitem:acd511f2c01f38405bfba0b6d5b2922e8"><td class="memItemLeft" align="right" valign="top">constexpr auto&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structboost_1_1hana_1_1set.html#acd511f2c01f38405bfba0b6d5b2922e8">union_</a></td></tr>
  170. <tr class="memdesc:acd511f2c01f38405bfba0b6d5b2922e8"><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns the union of two sets. <a href="#acd511f2c01f38405bfba0b6d5b2922e8">More...</a><br /></td></tr>
  171. <tr class="separator:acd511f2c01f38405bfba0b6d5b2922e8"><td class="memSeparator" colspan="2">&#160;</td></tr>
  172. <tr class="memitem:a3b3430482d4e88052e621f63a234f3eb"><td class="memItemLeft" align="right" valign="top">constexpr auto&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structboost_1_1hana_1_1set.html#a3b3430482d4e88052e621f63a234f3eb">intersection</a></td></tr>
  173. <tr class="memdesc:a3b3430482d4e88052e621f63a234f3eb"><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns the intersection of two sets. <a href="#a3b3430482d4e88052e621f63a234f3eb">More...</a><br /></td></tr>
  174. <tr class="separator:a3b3430482d4e88052e621f63a234f3eb"><td class="memSeparator" colspan="2">&#160;</td></tr>
  175. <tr class="memitem:accbea694d32b341e860dac724c0c6933"><td class="memItemLeft" align="right" valign="top">constexpr auto&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structboost_1_1hana_1_1set.html#accbea694d32b341e860dac724c0c6933">to_set</a> = <a class="el" href="group__group-core.html#gadc70755c1d059139297814fb3bfeb91e">to</a>&lt;<a class="el" href="structboost_1_1hana_1_1set__tag.html">set_tag</a>&gt;</td></tr>
  176. <tr class="memdesc:accbea694d32b341e860dac724c0c6933"><td class="mdescLeft">&#160;</td><td class="mdescRight">Equivalent to <code>to&lt;<a class="el" href="structboost_1_1hana_1_1set__tag.html" title="Tag representing the hana::set container.">set_tag</a>&gt;</code>; provided for convenience. <a href="#accbea694d32b341e860dac724c0c6933">More...</a><br /></td></tr>
  177. <tr class="separator:accbea694d32b341e860dac724c0c6933"><td class="memSeparator" colspan="2">&#160;</td></tr>
  178. <tr class="memitem:a718ddfe86437adbbca1e1a5db651d139"><td class="memItemLeft" align="right" valign="top">constexpr auto&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structboost_1_1hana_1_1set.html#a718ddfe86437adbbca1e1a5db651d139">difference</a></td></tr>
  179. <tr class="memdesc:a718ddfe86437adbbca1e1a5db651d139"><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns the set-theoretic difference of two sets. <a href="#a718ddfe86437adbbca1e1a5db651d139">More...</a><br /></td></tr>
  180. <tr class="separator:a718ddfe86437adbbca1e1a5db651d139"><td class="memSeparator" colspan="2">&#160;</td></tr>
  181. <tr class="memitem:a8bcb2455eb9f7074185d8fb61a99801e"><td class="memItemLeft" align="right" valign="top">constexpr auto&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structboost_1_1hana_1_1set.html#a8bcb2455eb9f7074185d8fb61a99801e">symmetric_difference</a></td></tr>
  182. <tr class="memdesc:a8bcb2455eb9f7074185d8fb61a99801e"><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns the symmetric set-theoretic difference of two sets. <a href="#a8bcb2455eb9f7074185d8fb61a99801e">More...</a><br /></td></tr>
  183. <tr class="separator:a8bcb2455eb9f7074185d8fb61a99801e"><td class="memSeparator" colspan="2">&#160;</td></tr>
  184. </table><table class="memberdecls">
  185. <tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="friends"></a>
  186. Friends</h2></td></tr>
  187. <tr class="memitem:a27607958295e6da8a0ba602a2db468f1"><td class="memTemplParams" colspan="2"><a id="a27607958295e6da8a0ba602a2db468f1"></a>
  188. template&lt;typename X , typename Y &gt; </td></tr>
  189. <tr class="memitem:a27607958295e6da8a0ba602a2db468f1"><td class="memTemplItemLeft" align="right" valign="top">constexpr auto&#160;</td><td class="memTemplItemRight" valign="bottom"><a class="el" href="structboost_1_1hana_1_1set.html#a27607958295e6da8a0ba602a2db468f1">operator==</a> (X &amp;&amp;x, Y &amp;&amp;y)</td></tr>
  190. <tr class="memdesc:a27607958295e6da8a0ba602a2db468f1"><td class="mdescLeft">&#160;</td><td class="mdescRight">Equivalent to <code><a class="el" href="group__group-Comparable.html#gacaf1ebea6b3ab96ac9dcb82f0e64e547" title="Returns a Logical representing whether x is equal to y.The equal function can be called in two differ...">hana::equal</a></code> <br /></td></tr>
  191. <tr class="separator:a27607958295e6da8a0ba602a2db468f1"><td class="memSeparator" colspan="2">&#160;</td></tr>
  192. <tr class="memitem:a0cae3af55edb3eb05bfa184bda633f7d"><td class="memTemplParams" colspan="2"><a id="a0cae3af55edb3eb05bfa184bda633f7d"></a>
  193. template&lt;typename X , typename Y &gt; </td></tr>
  194. <tr class="memitem:a0cae3af55edb3eb05bfa184bda633f7d"><td class="memTemplItemLeft" align="right" valign="top">constexpr auto&#160;</td><td class="memTemplItemRight" valign="bottom"><a class="el" href="structboost_1_1hana_1_1set.html#a0cae3af55edb3eb05bfa184bda633f7d">operator!=</a> (X &amp;&amp;x, Y &amp;&amp;y)</td></tr>
  195. <tr class="memdesc:a0cae3af55edb3eb05bfa184bda633f7d"><td class="mdescLeft">&#160;</td><td class="mdescRight">Equivalent to <code><a class="el" href="group__group-Comparable.html#gae33be2e0d5e04f19082f4b7740dfc9cd" title="Returns a Logical representing whether x is not equal to y.The not_equal function can be called in tw...">hana::not_equal</a></code> <br /></td></tr>
  196. <tr class="separator:a0cae3af55edb3eb05bfa184bda633f7d"><td class="memSeparator" colspan="2">&#160;</td></tr>
  197. </table><table class="memberdecls">
  198. <tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-methods"></a>
  199. Public Member Functions</h2></td></tr>
  200. <tr class="memitem:a51bdb213a03abc126668c4c3b14fc50b"><td class="memItemLeft" align="right" valign="top"><a id="a51bdb213a03abc126668c4c3b14fc50b"></a>
  201. constexpr&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structboost_1_1hana_1_1set.html#a51bdb213a03abc126668c4c3b14fc50b">set</a> ()=default</td></tr>
  202. <tr class="memdesc:a51bdb213a03abc126668c4c3b14fc50b"><td class="mdescLeft">&#160;</td><td class="mdescRight">Default-construct a set. This constructor only exists when all the elements of the set are default-constructible. <br /></td></tr>
  203. <tr class="separator:a51bdb213a03abc126668c4c3b14fc50b"><td class="memSeparator" colspan="2">&#160;</td></tr>
  204. <tr class="memitem:a937a7d47238690b571e7dd524278f6d5"><td class="memItemLeft" align="right" valign="top"><a id="a937a7d47238690b571e7dd524278f6d5"></a>
  205. constexpr&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structboost_1_1hana_1_1set.html#a937a7d47238690b571e7dd524278f6d5">set</a> (<a class="el" href="structboost_1_1hana_1_1set.html">set</a> const &amp;other)=default</td></tr>
  206. <tr class="memdesc:a937a7d47238690b571e7dd524278f6d5"><td class="mdescLeft">&#160;</td><td class="mdescRight">Copy-construct a set from another set. This constructor only exists when all the elements of the set are copy-constructible. <br /></td></tr>
  207. <tr class="separator:a937a7d47238690b571e7dd524278f6d5"><td class="memSeparator" colspan="2">&#160;</td></tr>
  208. <tr class="memitem:ac5b7025edfb0c6c28f31d84598e130f0"><td class="memItemLeft" align="right" valign="top"><a id="ac5b7025edfb0c6c28f31d84598e130f0"></a>
  209. constexpr&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structboost_1_1hana_1_1set.html#ac5b7025edfb0c6c28f31d84598e130f0">set</a> (<a class="el" href="structboost_1_1hana_1_1set.html">set</a> &amp;&amp;other)=default</td></tr>
  210. <tr class="memdesc:ac5b7025edfb0c6c28f31d84598e130f0"><td class="mdescLeft">&#160;</td><td class="mdescRight">Move-construct a set from another set. This constructor only exists when all the elements of the set are move-constructible. <br /></td></tr>
  211. <tr class="separator:ac5b7025edfb0c6c28f31d84598e130f0"><td class="memSeparator" colspan="2">&#160;</td></tr>
  212. <tr class="memitem:a00f6165e7a2db4218c67d80929c457d2"><td class="memTemplParams" colspan="2"><a id="a00f6165e7a2db4218c67d80929c457d2"></a>
  213. template&lt;typename Key &gt; </td></tr>
  214. <tr class="memitem:a00f6165e7a2db4218c67d80929c457d2"><td class="memTemplItemLeft" align="right" valign="top">decltype(auto) constexpr&#160;</td><td class="memTemplItemRight" valign="bottom"><a class="el" href="structboost_1_1hana_1_1set.html#a00f6165e7a2db4218c67d80929c457d2">operator[]</a> (Key &amp;&amp;key)</td></tr>
  215. <tr class="memdesc:a00f6165e7a2db4218c67d80929c457d2"><td class="mdescLeft">&#160;</td><td class="mdescRight">Equivalent to <code><a class="el" href="group__group-Searchable.html#ga3c1826aee6c6eb577810bb99c5c3e53d" title="Returns the value associated to the given key in a structure, or fail.Given a key and a Searchable st...">hana::at_key</a></code> <br /></td></tr>
  216. <tr class="separator:a00f6165e7a2db4218c67d80929c457d2"><td class="memSeparator" colspan="2">&#160;</td></tr>
  217. </table>
  218. <h2 class="groupheader">Associated functions</h2>
  219. <a id="aa337857e80b8a8c91880b0184aaf7534"></a>
  220. <h2 class="memtitle"><span class="permalink"><a href="#aa337857e80b8a8c91880b0184aaf7534">&#9670;&nbsp;</a></span>make&lt; set_tag &gt;</h2>
  221. <div class="memitem">
  222. <div class="memproto">
  223. <div class="memtemplate">
  224. template&lt;typename implementation_defined &gt; </div>
  225. <div class="memtemplate">
  226. template&lt;&gt; </div>
  227. <table class="mlabels">
  228. <tr>
  229. <td class="mlabels-left">
  230. <table class="memname">
  231. <tr>
  232. <td class="memname">constexpr auto <a class="el" href="group__group-core.html#ga1d92480f0af1029878e773dafa3e2f60">make</a>&lt; <a class="el" href="structboost_1_1hana_1_1set__tag.html">set_tag</a> &gt;</td>
  233. </tr>
  234. </table>
  235. </td>
  236. <td class="mlabels-right">
  237. <span class="mlabels"><span class="mlabel">related</span></span> </td>
  238. </tr>
  239. </table>
  240. </div><div class="memdoc">
  241. <b>Initial value:</b><div class="fragment"><div class="line">= [](<span class="keyword">auto</span>&amp;&amp; ...xs) {</div><div class="line"> <span class="keywordflow">return</span> set&lt;implementation_defined&gt;{forwarded(xs)...};</div><div class="line"> }</div></div><!-- fragment -->
  242. <p>Function object for creating a <code><a class="el" href="structboost_1_1hana_1_1set.html" title="Basic unordered container requiring unique, Comparable and Hashable keys.">hana::set</a></code>. </p>
  243. <p>Given zero or more values <code>xs...</code>, <code>make&lt;<a class="el" href="structboost_1_1hana_1_1set__tag.html" title="Tag representing the hana::set container.">set_tag</a>&gt;</code> returns a <code>set</code> containing those values. The values must all be compile-time <code>Comparable</code>, and no duplicate values may be provided. To create a <code>set</code> from a sequence with possible duplicates, use <code>to&lt;<a class="el" href="structboost_1_1hana_1_1set__tag.html" title="Tag representing the hana::set container.">set_tag</a>&gt;</code> instead.</p>
  244. <h2>Example </h2>
  245. <div class="fragment"><div class="line"><span class="comment">// Copyright Louis Dionne 2013-2017</span></div><div class="line"><span class="comment">// Distributed under the Boost Software License, Version 1.0.</span></div><div class="line"><span class="comment">// (See accompanying file LICENSE.md or copy at http://boost.org/LICENSE_1_0.txt)</span></div><div class="line"></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="assert_8hpp.html">boost/hana/assert.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="core_2make_8hpp.html">boost/hana/core/make.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="equal_8hpp.html">boost/hana/equal.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="integral__constant_8hpp.html">boost/hana/integral_constant.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="set_8hpp.html">boost/hana/set.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="type_8hpp.html">boost/hana/type.hpp</a>&gt;</span></div><div class="line"><span class="keyword">namespace </span>hana = <a class="code" href="namespaceboost_1_1hana.html">boost::hana</a>;</div><div class="line"></div><div class="line"></div><div class="line">constexpr <span class="keyword">auto</span> xs = hana::make_set(hana::int_c&lt;1&gt;, hana::type_c&lt;void&gt;);</div><div class="line"><a class="code" href="group__group-assertions.html#ga2c5006540936d9f8880e3a39f4fcc035">BOOST_HANA_CONSTANT_CHECK</a>(xs == hana::make&lt;hana::set_tag&gt;(hana::int_c&lt;1&gt;, hana::type_c&lt;void&gt;));</div><div class="line"></div><div class="line"><span class="keywordtype">int</span> main() { }</div></div><!-- fragment -->
  246. </div>
  247. </div>
  248. <a id="af38c23fb98d8eec68c1491a8bca9ce43"></a>
  249. <h2 class="memtitle"><span class="permalink"><a href="#af38c23fb98d8eec68c1491a8bca9ce43">&#9670;&nbsp;</a></span>make_set</h2>
  250. <div class="memitem">
  251. <div class="memproto">
  252. <div class="memtemplate">
  253. template&lt;typename implementation_defined &gt; </div>
  254. <table class="mlabels">
  255. <tr>
  256. <td class="mlabels-left">
  257. <table class="memname">
  258. <tr>
  259. <td class="memname">constexpr auto make_set = <a class="el" href="group__group-core.html#ga1d92480f0af1029878e773dafa3e2f60">make</a>&lt;<a class="el" href="structboost_1_1hana_1_1set__tag.html">set_tag</a>&gt;</td>
  260. </tr>
  261. </table>
  262. </td>
  263. <td class="mlabels-right">
  264. <span class="mlabels"><span class="mlabel">related</span></span> </td>
  265. </tr>
  266. </table>
  267. </div><div class="memdoc">
  268. <p>Equivalent to <code>make&lt;<a class="el" href="structboost_1_1hana_1_1set__tag.html" title="Tag representing the hana::set container.">set_tag</a>&gt;</code>; provided for convenience. </p>
  269. <h2>Example </h2>
  270. <div class="fragment"><div class="line"><span class="comment">// Copyright Louis Dionne 2013-2017</span></div><div class="line"><span class="comment">// Distributed under the Boost Software License, Version 1.0.</span></div><div class="line"><span class="comment">// (See accompanying file LICENSE.md or copy at http://boost.org/LICENSE_1_0.txt)</span></div><div class="line"></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="assert_8hpp.html">boost/hana/assert.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="core_2make_8hpp.html">boost/hana/core/make.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="equal_8hpp.html">boost/hana/equal.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="integral__constant_8hpp.html">boost/hana/integral_constant.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="set_8hpp.html">boost/hana/set.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="type_8hpp.html">boost/hana/type.hpp</a>&gt;</span></div><div class="line"><span class="keyword">namespace </span>hana = <a class="code" href="namespaceboost_1_1hana.html">boost::hana</a>;</div><div class="line"></div><div class="line"></div><div class="line">constexpr <span class="keyword">auto</span> xs = hana::make_set(hana::int_c&lt;1&gt;, hana::type_c&lt;void&gt;);</div><div class="line"><a class="code" href="group__group-assertions.html#ga2c5006540936d9f8880e3a39f4fcc035">BOOST_HANA_CONSTANT_CHECK</a>(xs == hana::make&lt;hana::set_tag&gt;(hana::int_c&lt;1&gt;, hana::type_c&lt;void&gt;));</div><div class="line"></div><div class="line"><span class="keywordtype">int</span> main() { }</div></div><!-- fragment -->
  271. </div>
  272. </div>
  273. <a id="a5791e6dc0e27d8e3a113e4d94482550f"></a>
  274. <h2 class="memtitle"><span class="permalink"><a href="#a5791e6dc0e27d8e3a113e4d94482550f">&#9670;&nbsp;</a></span>insert</h2>
  275. <div class="memitem">
  276. <div class="memproto">
  277. <div class="memtemplate">
  278. template&lt;typename implementation_defined &gt; </div>
  279. <table class="mlabels">
  280. <tr>
  281. <td class="mlabels-left">
  282. <table class="memname">
  283. <tr>
  284. <td class="memname">constexpr auto insert</td>
  285. </tr>
  286. </table>
  287. </td>
  288. <td class="mlabels-right">
  289. <span class="mlabels"><span class="mlabel">related</span></span> </td>
  290. </tr>
  291. </table>
  292. </div><div class="memdoc">
  293. <b>Initial value:</b><div class="fragment"><div class="line">= [](<span class="keyword">auto</span>&amp;&amp; <a class="code" href="structboost_1_1hana_1_1set.html#a51bdb213a03abc126668c4c3b14fc50b">set</a>, <span class="keyword">auto</span>&amp;&amp; element) {</div><div class="line"> <span class="keywordflow">return</span> tag-dispatched;</div><div class="line"> }</div></div><!-- fragment -->
  294. <p>Insert an element in a <code><a class="el" href="structboost_1_1hana_1_1set.html" title="Basic unordered container requiring unique, Comparable and Hashable keys.">hana::set</a></code>. </p>
  295. <p>If the set already contains an element that compares equal, then nothing is done and the set is returned as is.</p>
  296. <dl class="params"><dt>Parameters</dt><dd>
  297. <table class="params">
  298. <tr><td class="paramname">set</td><td>The set in which to insert a value.</td></tr>
  299. <tr><td class="paramname">element</td><td>The value to insert. It must be compile-time <code>Comparable</code>.</td></tr>
  300. </table>
  301. </dd>
  302. </dl>
  303. <h2>Example </h2>
  304. <div class="fragment"><div class="line"><span class="comment">// Copyright Louis Dionne 2013-2017</span></div><div class="line"><span class="comment">// Distributed under the Boost Software License, Version 1.0.</span></div><div class="line"><span class="comment">// (See accompanying file LICENSE.md or copy at http://boost.org/LICENSE_1_0.txt)</span></div><div class="line"></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="assert_8hpp.html">boost/hana/assert.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="equal_8hpp.html">boost/hana/equal.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="insert_8hpp.html">boost/hana/insert.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="integral__constant_8hpp.html">boost/hana/integral_constant.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="set_8hpp.html">boost/hana/set.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="string_8hpp.html">boost/hana/string.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="type_8hpp.html">boost/hana/type.hpp</a>&gt;</span></div><div class="line"><span class="keyword">namespace </span>hana = <a class="code" href="namespaceboost_1_1hana.html">boost::hana</a>;</div><div class="line"></div><div class="line"></div><div class="line"><span class="keywordtype">int</span> main() {</div><div class="line"> constexpr <span class="keyword">auto</span> xs = hana::make_set(hana::int_c&lt;0&gt;, hana::type_c&lt;int&gt;);</div><div class="line"> <a class="code" href="group__group-assertions.html#ga2c5006540936d9f8880e3a39f4fcc035">BOOST_HANA_CONSTANT_CHECK</a>(</div><div class="line"> <a class="code" href="group__group-Sequence.html#gae22a1a184b1b2dd550fa4fa619bed2e9">hana::insert</a>(xs, BOOST_HANA_STRING(<span class="stringliteral">&quot;abc&quot;</span>)) ==</div><div class="line"> hana::make_set(hana::int_c&lt;0&gt;, hana::type_c&lt;int&gt;, BOOST_HANA_STRING(<span class="stringliteral">&quot;abc&quot;</span>))</div><div class="line"> );</div><div class="line"></div><div class="line"> <a class="code" href="group__group-assertions.html#ga2c5006540936d9f8880e3a39f4fcc035">BOOST_HANA_CONSTANT_CHECK</a>(</div><div class="line"> <a class="code" href="group__group-Sequence.html#gae22a1a184b1b2dd550fa4fa619bed2e9">hana::insert</a>(xs, hana::int_c&lt;0&gt;) == hana::make_set(hana::int_c&lt;0&gt;, hana::type_c&lt;int&gt;)</div><div class="line"> );</div><div class="line">}</div></div><!-- fragment -->
  305. </div>
  306. </div>
  307. <a id="af856f7bf77f69cdf1b8fd4e566eaef9b"></a>
  308. <h2 class="memtitle"><span class="permalink"><a href="#af856f7bf77f69cdf1b8fd4e566eaef9b">&#9670;&nbsp;</a></span>erase_key</h2>
  309. <div class="memitem">
  310. <div class="memproto">
  311. <div class="memtemplate">
  312. template&lt;typename implementation_defined &gt; </div>
  313. <table class="mlabels">
  314. <tr>
  315. <td class="mlabels-left">
  316. <table class="memname">
  317. <tr>
  318. <td class="memname">constexpr auto erase_key</td>
  319. </tr>
  320. </table>
  321. </td>
  322. <td class="mlabels-right">
  323. <span class="mlabels"><span class="mlabel">related</span></span> </td>
  324. </tr>
  325. </table>
  326. </div><div class="memdoc">
  327. <b>Initial value:</b><div class="fragment"><div class="line">= [](<span class="keyword">auto</span>&amp;&amp; <a class="code" href="structboost_1_1hana_1_1set.html#a51bdb213a03abc126668c4c3b14fc50b">set</a>, <span class="keyword">auto</span>&amp;&amp; element) {</div><div class="line"> <span class="keywordflow">return</span> tag-dispatched;</div><div class="line"> }</div></div><!-- fragment -->
  328. <p>Remove an element from a <code><a class="el" href="structboost_1_1hana_1_1set.html" title="Basic unordered container requiring unique, Comparable and Hashable keys.">hana::set</a></code>. </p>
  329. <p>Returns a new set containing all the elements of the original, except the one comparing <code>equal</code> to the given element. If the set does not contain such an element, a new set equal to the original set is returned.</p>
  330. <dl class="params"><dt>Parameters</dt><dd>
  331. <table class="params">
  332. <tr><td class="paramname">set</td><td>The set in which to remove a value.</td></tr>
  333. <tr><td class="paramname">element</td><td>The value to remove. It must be compile-time <code>Comparable</code>.</td></tr>
  334. </table>
  335. </dd>
  336. </dl>
  337. <h2>Example </h2>
  338. <div class="fragment"><div class="line"><span class="comment">// Copyright Louis Dionne 2013-2017</span></div><div class="line"><span class="comment">// Distributed under the Boost Software License, Version 1.0.</span></div><div class="line"><span class="comment">// (See accompanying file LICENSE.md or copy at http://boost.org/LICENSE_1_0.txt)</span></div><div class="line"></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="assert_8hpp.html">boost/hana/assert.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="equal_8hpp.html">boost/hana/equal.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="erase__key_8hpp.html">boost/hana/erase_key.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="integral__constant_8hpp.html">boost/hana/integral_constant.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="set_8hpp.html">boost/hana/set.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="type_8hpp.html">boost/hana/type.hpp</a>&gt;</span></div><div class="line"><span class="keyword">namespace </span>hana = <a class="code" href="namespaceboost_1_1hana.html">boost::hana</a>;</div><div class="line"></div><div class="line"></div><div class="line"><span class="keywordtype">int</span> main() {</div><div class="line"> constexpr <span class="keyword">auto</span> xs = hana::make_set(hana::int_c&lt;0&gt;, hana::type_c&lt;int&gt;, hana::type_c&lt;void&gt;);</div><div class="line"></div><div class="line"> <a class="code" href="group__group-assertions.html#ga2c5006540936d9f8880e3a39f4fcc035">BOOST_HANA_CONSTANT_CHECK</a>(hana::erase_key(xs, hana::type_c&lt;int&gt;) == hana::make_set(hana::int_c&lt;0&gt;, hana::type_c&lt;void&gt;));</div><div class="line"> <a class="code" href="group__group-assertions.html#ga2c5006540936d9f8880e3a39f4fcc035">BOOST_HANA_CONSTANT_CHECK</a>(hana::erase_key(xs, hana::type_c&lt;char&gt;) == xs);</div><div class="line">}</div></div><!-- fragment -->
  339. </div>
  340. </div>
  341. <a id="acd511f2c01f38405bfba0b6d5b2922e8"></a>
  342. <h2 class="memtitle"><span class="permalink"><a href="#acd511f2c01f38405bfba0b6d5b2922e8">&#9670;&nbsp;</a></span>union_</h2>
  343. <div class="memitem">
  344. <div class="memproto">
  345. <div class="memtemplate">
  346. template&lt;typename implementation_defined &gt; </div>
  347. <table class="mlabels">
  348. <tr>
  349. <td class="mlabels-left">
  350. <table class="memname">
  351. <tr>
  352. <td class="memname">constexpr auto union_</td>
  353. </tr>
  354. </table>
  355. </td>
  356. <td class="mlabels-right">
  357. <span class="mlabels"><span class="mlabel">related</span></span> </td>
  358. </tr>
  359. </table>
  360. </div><div class="memdoc">
  361. <b>Initial value:</b><div class="fragment"><div class="line">= [](<span class="keyword">auto</span>&amp;&amp; xs, <span class="keyword">auto</span>&amp;&amp; ys) {</div><div class="line"> <span class="keywordflow">return</span> tag-dispatched;</div><div class="line"> }</div></div><!-- fragment -->
  362. <p>Returns the union of two sets. </p>
  363. <p>Given two sets <code>xs</code> and <code>ys</code>, <code>union_(xs, ys)</code> is a new set containing all the elements of <code>xs</code> and all the elements of <code>ys</code>, without duplicates. For any object <code>x</code>, the following holds: <code>x</code> is in <code>hana::union_(xs, ys)</code> if and only if <code>x</code> is in <code>xs</code> or <code>x</code> is in <code>ys</code>.</p>
  364. <dl class="params"><dt>Parameters</dt><dd>
  365. <table class="params">
  366. <tr><td class="paramname">xs,ys</td><td>Two sets to compute the union of.</td></tr>
  367. </table>
  368. </dd>
  369. </dl>
  370. <h2>Example </h2>
  371. <div class="fragment"><div class="line"><span class="comment">// Copyright Louis Dionne 2013-2017</span></div><div class="line"><span class="comment">// Distributed under the Boost Software License, Version 1.0.</span></div><div class="line"><span class="comment">// (See accompanying file LICENSE.md or copy at http://boost.org/LICENSE_1_0.txt)</span></div><div class="line"></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="assert_8hpp.html">boost/hana/assert.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="equal_8hpp.html">boost/hana/equal.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="integral__constant_8hpp.html">boost/hana/integral_constant.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="set_8hpp.html">boost/hana/set.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="string_8hpp.html">boost/hana/string.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="type_8hpp.html">boost/hana/type.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="union_8hpp.html">boost/hana/union.hpp</a>&gt;</span></div><div class="line"><span class="keyword">namespace </span>hana = <a class="code" href="namespaceboost_1_1hana.html">boost::hana</a>;</div><div class="line"><span class="keyword">using namespace </span>hana::literals;</div><div class="line"></div><div class="line"></div><div class="line">constexpr <span class="keyword">auto</span> xs = hana::make_set(hana::int_c&lt;1&gt;, hana::type_c&lt;void&gt;, hana::int_c&lt;2&gt;);</div><div class="line">constexpr <span class="keyword">auto</span> ys = hana::make_set(hana::int_c&lt;2&gt;, hana::type_c&lt;int&gt;, hana::int_c&lt;3&gt;);</div><div class="line"></div><div class="line"><a class="code" href="group__group-assertions.html#ga2c5006540936d9f8880e3a39f4fcc035">BOOST_HANA_CONSTANT_CHECK</a>(hana::union_(xs, ys) == hana::make_set(</div><div class="line"> hana::int_c&lt;1&gt;, hana::int_c&lt;2&gt;, hana::int_c&lt;3&gt;, hana::type_c&lt;void&gt;, hana::type_c&lt;int&gt;</div><div class="line">));</div><div class="line"></div><div class="line"><span class="keywordtype">int</span> main() { }</div></div><!-- fragment -->
  372. </div>
  373. </div>
  374. <a id="a3b3430482d4e88052e621f63a234f3eb"></a>
  375. <h2 class="memtitle"><span class="permalink"><a href="#a3b3430482d4e88052e621f63a234f3eb">&#9670;&nbsp;</a></span>intersection</h2>
  376. <div class="memitem">
  377. <div class="memproto">
  378. <div class="memtemplate">
  379. template&lt;typename implementation_defined &gt; </div>
  380. <table class="mlabels">
  381. <tr>
  382. <td class="mlabels-left">
  383. <table class="memname">
  384. <tr>
  385. <td class="memname">constexpr auto intersection</td>
  386. </tr>
  387. </table>
  388. </td>
  389. <td class="mlabels-right">
  390. <span class="mlabels"><span class="mlabel">related</span></span> </td>
  391. </tr>
  392. </table>
  393. </div><div class="memdoc">
  394. <b>Initial value:</b><div class="fragment"><div class="line">= [](<span class="keyword">auto</span>&amp;&amp; xs, <span class="keyword">auto</span>&amp;&amp; ys) {</div><div class="line"> <span class="keywordflow">return</span> tag-dispatched;</div><div class="line"> }</div></div><!-- fragment -->
  395. <p>Returns the intersection of two sets. </p>
  396. <p>Given two sets <code>xs</code> and <code>ys</code>, <code>intersection(xs, ys)</code> is a new set containing exactly those elements that are present both in <code>xs</code> and in <code>ys</code>. In other words, the following holds for any object <code>x</code>: </p><div class="fragment"><div class="line">x ^<a class="code" href="group__group-Searchable.html#ga0d9456ceda38b6ca664998e79d7c45b7">in</a>^ <a class="code" href="structboost_1_1hana_1_1set.html#a3b3430482d4e88052e621f63a234f3eb">intersection</a>(xs, ys) <span class="keywordflow">if</span> and only <span class="keywordflow">if</span> x ^<a class="code" href="group__group-Searchable.html#ga0d9456ceda38b6ca664998e79d7c45b7">in</a>^ xs &amp;&amp; x ^<a class="code" href="group__group-Searchable.html#ga0d9456ceda38b6ca664998e79d7c45b7">in</a>^ ys</div></div><!-- fragment --><dl class="params"><dt>Parameters</dt><dd>
  397. <table class="params">
  398. <tr><td class="paramname">xs,ys</td><td>Two sets to intersect.</td></tr>
  399. </table>
  400. </dd>
  401. </dl>
  402. <h2>Example </h2>
  403. <div class="fragment"><div class="line"><span class="comment">// Copyright Louis Dionne 2013-2017</span></div><div class="line"><span class="comment">// Distributed under the Boost Software License, Version 1.0.</span></div><div class="line"><span class="comment">// (See accompanying file LICENSE.md or copy at http://boost.org/LICENSE_1_0.txt)</span></div><div class="line"></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="assert_8hpp.html">boost/hana/assert.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="equal_8hpp.html">boost/hana/equal.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="integral__constant_8hpp.html">boost/hana/integral_constant.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="intersection_8hpp.html">boost/hana/intersection.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="set_8hpp.html">boost/hana/set.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="type_8hpp.html">boost/hana/type.hpp</a>&gt;</span></div><div class="line"><span class="keyword">namespace </span>hana = <a class="code" href="namespaceboost_1_1hana.html">boost::hana</a>;</div><div class="line"></div><div class="line"></div><div class="line">constexpr <span class="keyword">auto</span> xs = hana::make_set(hana::int_c&lt;1&gt;, hana::type_c&lt;void&gt;, hana::int_c&lt;2&gt;);</div><div class="line">constexpr <span class="keyword">auto</span> ys = hana::make_set(hana::int_c&lt;2&gt;, hana::type_c&lt;int&gt;, hana::int_c&lt;3&gt;);</div><div class="line"></div><div class="line"><a class="code" href="group__group-assertions.html#ga2c5006540936d9f8880e3a39f4fcc035">BOOST_HANA_CONSTANT_CHECK</a>(hana::intersection(xs, ys) == hana::make_set(hana::int_c&lt;2&gt;));</div><div class="line"></div><div class="line"><span class="keywordtype">int</span> main() { }</div></div><!-- fragment -->
  404. </div>
  405. </div>
  406. <a id="accbea694d32b341e860dac724c0c6933"></a>
  407. <h2 class="memtitle"><span class="permalink"><a href="#accbea694d32b341e860dac724c0c6933">&#9670;&nbsp;</a></span>to_set</h2>
  408. <div class="memitem">
  409. <div class="memproto">
  410. <div class="memtemplate">
  411. template&lt;typename implementation_defined &gt; </div>
  412. <table class="mlabels">
  413. <tr>
  414. <td class="mlabels-left">
  415. <table class="memname">
  416. <tr>
  417. <td class="memname">constexpr auto to_set = <a class="el" href="group__group-core.html#gadc70755c1d059139297814fb3bfeb91e">to</a>&lt;<a class="el" href="structboost_1_1hana_1_1set__tag.html">set_tag</a>&gt;</td>
  418. </tr>
  419. </table>
  420. </td>
  421. <td class="mlabels-right">
  422. <span class="mlabels"><span class="mlabel">related</span></span> </td>
  423. </tr>
  424. </table>
  425. </div><div class="memdoc">
  426. <p>Equivalent to <code>to&lt;<a class="el" href="structboost_1_1hana_1_1set__tag.html" title="Tag representing the hana::set container.">set_tag</a>&gt;</code>; provided for convenience. </p>
  427. </div>
  428. </div>
  429. <a id="a718ddfe86437adbbca1e1a5db651d139"></a>
  430. <h2 class="memtitle"><span class="permalink"><a href="#a718ddfe86437adbbca1e1a5db651d139">&#9670;&nbsp;</a></span>difference</h2>
  431. <div class="memitem">
  432. <div class="memproto">
  433. <div class="memtemplate">
  434. template&lt;typename implementation_defined &gt; </div>
  435. <table class="mlabels">
  436. <tr>
  437. <td class="mlabels-left">
  438. <table class="memname">
  439. <tr>
  440. <td class="memname">constexpr auto difference</td>
  441. </tr>
  442. </table>
  443. </td>
  444. <td class="mlabels-right">
  445. <span class="mlabels"><span class="mlabel">related</span></span> </td>
  446. </tr>
  447. </table>
  448. </div><div class="memdoc">
  449. <b>Initial value:</b><div class="fragment"><div class="line">= [](<span class="keyword">auto</span>&amp;&amp; xs, <span class="keyword">auto</span>&amp;&amp; ys) {</div><div class="line"> <span class="keywordflow">return</span> tag-dispatched;</div><div class="line">}</div></div><!-- fragment -->
  450. <p>Returns the set-theoretic difference of two sets. </p>
  451. <p>Given two sets <code>xs</code> and <code>ys</code>, <code>difference(xs, ys)</code> is a new set containing all the elements of <code>xs</code> that are <em>not</em> contained in <code>ys</code>. For any object <code>x</code>, the following holds: </p><div class="fragment"><div class="line">x ^<a class="code" href="group__group-Searchable.html#ga0d9456ceda38b6ca664998e79d7c45b7">in</a>^ <a class="code" href="structboost_1_1hana_1_1set.html#a718ddfe86437adbbca1e1a5db651d139">difference</a>(xs, ys) <span class="keywordflow">if</span> and only <span class="keywordflow">if</span> x ^<a class="code" href="group__group-Searchable.html#ga0d9456ceda38b6ca664998e79d7c45b7">in</a>^ xs &amp;&amp; !(x ^<a class="code" href="group__group-Searchable.html#ga0d9456ceda38b6ca664998e79d7c45b7">in</a>^ ys)</div></div><!-- fragment --><p>This operation is not commutative, i.e. <code>difference(xs, ys)</code> is not necessarily the same as <code>difference(ys, xs)</code>. Indeed, consider the case where <code>xs</code> is empty and <code>ys</code> isn't. Then, <code>difference(xs, ys)</code> is empty but <code>difference(ys, xs)</code> is equal to <code>ys</code>. For the symmetric version of this operation, see <code>symmetric_difference</code>.</p>
  452. <dl class="params"><dt>Parameters</dt><dd>
  453. <table class="params">
  454. <tr><td class="paramname">xs</td><td>A set param to remove values from.</td></tr>
  455. <tr><td class="paramname">ys</td><td>The set whose values are removed from <code>xs</code>.</td></tr>
  456. </table>
  457. </dd>
  458. </dl>
  459. <h2>Example </h2>
  460. <div class="fragment"><div class="line"><span class="comment">// Copyright Louis Dionne 2013-2017</span></div><div class="line"><span class="comment">// Distributed under the Boost Software License, Version 1.0.</span></div><div class="line"><span class="comment">// (See accompanying file LICENSE.md or copy at http://boost.org/LICENSE_1_0.txt)</span></div><div class="line"></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="assert_8hpp.html">boost/hana/assert.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="difference_8hpp.html">boost/hana/difference.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="equal_8hpp.html">boost/hana/equal.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="integral__constant_8hpp.html">boost/hana/integral_constant.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="set_8hpp.html">boost/hana/set.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="type_8hpp.html">boost/hana/type.hpp</a>&gt;</span></div><div class="line"><span class="keyword">namespace </span>hana = <a class="code" href="namespaceboost_1_1hana.html">boost::hana</a>;</div><div class="line"></div><div class="line"></div><div class="line">constexpr <span class="keyword">auto</span> xs = hana::make_set(hana::int_c&lt;1&gt;, hana::int_c&lt;2&gt;, hana::type_c&lt;int&gt;, hana::int_c&lt;3&gt;);</div><div class="line">constexpr <span class="keyword">auto</span> ys = hana::make_set(hana::int_c&lt;3&gt;, hana::type_c&lt;void&gt;, hana::type_c&lt;int&gt;);</div><div class="line"></div><div class="line"><a class="code" href="group__group-assertions.html#ga2c5006540936d9f8880e3a39f4fcc035">BOOST_HANA_CONSTANT_CHECK</a>(hana::difference(xs, ys) == hana::make_set(hana::int_c&lt;1&gt;, hana::int_c&lt;2&gt;));</div><div class="line"><a class="code" href="group__group-assertions.html#ga2c5006540936d9f8880e3a39f4fcc035">BOOST_HANA_CONSTANT_CHECK</a>(hana::difference(ys, xs) == hana::make_set(hana::type_c&lt;void&gt;));</div><div class="line"></div><div class="line"><span class="keywordtype">int</span> main() { }</div></div><!-- fragment -->
  461. </div>
  462. </div>
  463. <a id="a8bcb2455eb9f7074185d8fb61a99801e"></a>
  464. <h2 class="memtitle"><span class="permalink"><a href="#a8bcb2455eb9f7074185d8fb61a99801e">&#9670;&nbsp;</a></span>symmetric_difference</h2>
  465. <div class="memitem">
  466. <div class="memproto">
  467. <div class="memtemplate">
  468. template&lt;typename implementation_defined &gt; </div>
  469. <table class="mlabels">
  470. <tr>
  471. <td class="mlabels-left">
  472. <table class="memname">
  473. <tr>
  474. <td class="memname">constexpr auto symmetric_difference</td>
  475. </tr>
  476. </table>
  477. </td>
  478. <td class="mlabels-right">
  479. <span class="mlabels"><span class="mlabel">related</span></span> </td>
  480. </tr>
  481. </table>
  482. </div><div class="memdoc">
  483. <b>Initial value:</b><div class="fragment"><div class="line">= [](<span class="keyword">auto</span>&amp;&amp; xs, <span class="keyword">auto</span>&amp;&amp; ys) {</div><div class="line"> <span class="keywordflow">return</span> tag-dispatched;</div><div class="line"> }</div></div><!-- fragment -->
  484. <p>Returns the symmetric set-theoretic difference of two sets. </p>
  485. <p>Given two sets <code>xs</code> and <code>ys</code>, <code>symmetric_difference(xs, ys)</code> is a new set containing all the elements of <code>xs</code> that are not contained in <code>ys</code>, and all the elements of <code>ys</code> that are not contained in <code>xs</code>. The symmetric difference of two sets satisfies the following: </p><div class="fragment"><div class="line"><a class="code" href="structboost_1_1hana_1_1set.html#a8bcb2455eb9f7074185d8fb61a99801e">symmetric_difference</a>(xs, ys) == <a class="code" href="structboost_1_1hana_1_1set.html#acd511f2c01f38405bfba0b6d5b2922e8">union_</a>(<a class="code" href="structboost_1_1hana_1_1set.html#a718ddfe86437adbbca1e1a5db651d139">difference</a>(xs, ys), <a class="code" href="structboost_1_1hana_1_1set.html#a718ddfe86437adbbca1e1a5db651d139">difference</a>(ys, xs))</div></div><!-- fragment --><dl class="params"><dt>Parameters</dt><dd>
  486. <table class="params">
  487. <tr><td class="paramname">xs,ys</td><td>Two sets to compute the symmetric difference of.</td></tr>
  488. </table>
  489. </dd>
  490. </dl>
  491. <h2>Example </h2>
  492. <div class="fragment"><div class="line"><span class="comment">// Copyright Louis Dionne 2013-2017</span></div><div class="line"><span class="comment">// Distributed under the Boost Software License, Version 1.0.</span></div><div class="line"><span class="comment">// (See accompanying file LICENSE.md or copy at http://boost.org/LICENSE_1_0.txt)</span></div><div class="line"></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="assert_8hpp.html">boost/hana/assert.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="set_8hpp.html">boost/hana/set.hpp</a>&gt;</span></div><div class="line"><span class="preprocessor">#include &lt;<a class="code" href="symmetric__difference_8hpp.html">boost/hana/symmetric_difference.hpp</a>&gt;</span></div><div class="line"></div><div class="line"><span class="keyword">namespace </span>hana = <a class="code" href="namespaceboost_1_1hana.html">boost::hana</a>;</div><div class="line"></div><div class="line"></div><div class="line">constexpr <span class="keyword">auto</span> xs = hana::make_set(hana::int_c&lt;1&gt;, hana::int_c&lt;2&gt;, hana::type_c&lt;int&gt;, hana::int_c&lt;3&gt;);</div><div class="line">constexpr <span class="keyword">auto</span> ys = hana::make_set(hana::int_c&lt;3&gt;, hana::type_c&lt;void&gt;, hana::type_c&lt;int&gt;);</div><div class="line"></div><div class="line"><a class="code" href="group__group-assertions.html#ga2c5006540936d9f8880e3a39f4fcc035">BOOST_HANA_CONSTANT_CHECK</a>(</div><div class="line"> hana::symmetric_difference(xs, ys) == hana::make_set(hana::int_c&lt;1&gt;, hana::int_c&lt;2&gt;, hana::type_c&lt;void&gt;)</div><div class="line">);</div><div class="line"></div><div class="line"><span class="keywordtype">int</span> main() { }</div></div><!-- fragment -->
  493. </div>
  494. </div>
  495. </div><!-- contents -->
  496. </div><!-- doc-content -->
  497. <!--
  498. Copyright Louis Dionne 2013-2017
  499. Distributed under the Boost Software License, Version 1.0.
  500. (See accompanying file LICENSE.md or copy at http://boost.org/LICENSE_1_0.txt)
  501. -->
  502. <!-- boost-no-inspect -->
  503. <!-- HTML footer for doxygen 1.8.9.1-->
  504. <!-- start footer part -->
  505. <div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
  506. <ul>
  507. <li class="navelem"><b>boost</b></li><li class="navelem"><a class="el" href="namespaceboost_1_1hana.html">hana</a></li><li class="navelem"><a class="el" href="structboost_1_1hana_1_1set.html">set</a></li>
  508. </ul>
  509. </div>
  510. </body>
  511. </html>