From 7f6e800cafc7b73625893fb5280eb8b51a15b252 Mon Sep 17 00:00:00 2001
From: flywind <xzsflywind@gmail.com>
Date: Thu, 24 Mar 2022 03:34:53 +0800
Subject: move assertions out of system (#19599)

---
 compiler/btrees.nim | 3 +++
 1 file changed, 3 insertions(+)

(limited to 'compiler/btrees.nim')

diff --git a/compiler/btrees.nim b/compiler/btrees.nim
index d5e7e8099..1701f8d7b 100644
--- a/compiler/btrees.nim
+++ b/compiler/btrees.nim
@@ -10,6 +10,9 @@
 ## BTree implementation with few features, but good enough for the
 ## Nim compiler's needs.
 
+when defined(nimPreviewSlimSystem):
+  import std/assertions
+
 const
   M = 512    # max children per B-tree node = M-1
              # (must be even and greater than 2)
-- 
cgit 1.4.1-2-gfad0

7dfadb8b4e95d09981fbeb01d85b12f23946c3e7'>this commit</option>
<optgroup label='branches'><option value='devel' selected='selected'>devel</option>
</optgroup></select> <input type='submit' value='switch'/></form></td></tr>
<tr><td class='sub'>This repository contains the Nim compiler, Nim's stdlib, tools, and documentation. (mirror)</td><td class='sub right'>ahoang &lt;ahoang@tilde.institute&gt;</td></tr></table>
<table class='tabs'><tr><td>
<a href='/ahoang/Nim/?h=devel'>summary</a> <a href='/ahoang/Nim/refs/?h=devel&amp;id=53fbb497e95b535172628cc60176845d0e458e94'>refs</a> <a href='/ahoang/Nim/log/build_all.sh?h=devel'>log</a> <a class='active' href='/ahoang/Nim/blame/build_all.sh?h=devel&amp;id=53fbb497e95b535172628cc60176845d0e458e94'>blame</a> <a href='/ahoang/Nim/commit/build_all.sh?h=devel&amp;id=53fbb497e95b535172628cc60176845d0e458e94'>commit</a> <a href='/ahoang/Nim/diff/build_all.sh?h=devel&amp;id=53fbb497e95b535172628cc60176845d0e458e94'>diff</a> <a href='/ahoang/Nim/stats/build_all.sh?h=devel'>stats</a></td><td class='form'><form class='right' method='get' action='/ahoang/Nim/log/build_all.sh'>
<input type='hidden' name='h' value='devel'/><input type='hidden' name='id' value='53fbb497e95b535172628cc60176845d0e458e94'/><select name='qt'>
<option value='grep'>log msg</option>
<option value='author'>author</option>
<option value='committer'>committer</option>
<option value='range'>range</option>
</select>
<input class='txt' type='search' size='10' name='q' value=''/>
<input type='submit' value='search'/>
</form>
</td></tr></table>
<div class='path'>path: <a href='/ahoang/Nim/blame/?h=devel&amp;id=53fbb497e95b535172628cc60176845d0e458e94'>root</a>/<a href='/ahoang/Nim/blame/build_all.sh?h=devel&amp;id=53fbb497e95b535172628cc60176845d0e458e94'>build_all.sh</a></div><div class='content'>blob: 83848f41a1def552635ee6a248677ac8f1d2be0f (<a href='/ahoang/Nim/plain/build_all.sh?h=devel&amp;id=53fbb497e95b535172628cc60176845d0e458e94'>plain</a>) (<a href='/ahoang/Nim/tree/build_all.sh?h=devel&amp;id=53fbb497e95b535172628cc60176845d0e458e94'>tree</a>)
<table class='blame blob'>
<tr>
<td class='hashes'><div class='alt'><pre><span class='oid'><a title='author  Timothee Cour &lt;timothee.cour2@gmail.com&gt;  2021-07-06 21:00:59 -0700
committer  GitHub &lt;noreply@github.com&gt;  2021-07-07 06:00:59 +0200

fix shebangs #! /xxx =&gt; #!/xxx (#18444)' href='/ahoang/Nim/commit/build_all.sh?h=devel&amp;id=b72ecaf639ca7b2edf5a762cfea3a11f7cc5da9a'>b72ecaf63</a></span> <a title='Blame the previous revision' href='/ahoang/Nim/blame/build_all.sh?h=devel&amp;id=b88496ac67bea92c40cf1d0f3dc55b0fa91550a4'>^</a>
</pre></div><div class='alt'><pre><span class='oid'><a title='author  Timothee Cour &lt;timothee.cour2@gmail.com&gt;  2021-05-01 10:43:20 -0700
committer  GitHub &lt;noreply@github.com&gt;  2021-05-01 10:43:20 -0700

ref #17913; fix typo in tools/ci_generate.nim generating build_all.sh (#17915)' href='/ahoang/Nim/commit/build_all.sh?h=devel&amp;id=13b57524d35a18df57bec2a7d6a2faa7ce712e9f'>13b57524d</a></span> <a title='Blame the previous revision' href='/ahoang/Nim/blame/build_all.sh?h=devel&amp;id=ee6d56141c11cf9273d3671eb9dd54097361cc1b'>^</a>
</pre></div><div class='alt'><pre><span class='oid'><a title='author  Timothee Cour &lt;timothee.cour2@gmail.com&gt;  2018-08-08 07:47:17 -0700
committer  Andreas Rumpf &lt;rumpf_a@web.de&gt;  2018-08-08 16:47:17 +0200

add build_all.sh to allow 1-liner to build development version of the compiler (#8546)' href='/ahoang/Nim/commit/build_all.sh?h=devel&amp;id=506418ef539a9142307235c0cd0183f0d7aec749'>506418ef5</a></span> <a title='Blame the previous revision' href='/ahoang/Nim/blame/build_all.sh?h=devel&amp;id=32b62097a2636c5053d842939d34e2a0fa3f9e33'>^</a>
</pre></div><div class='alt'><pre><span class='oid'><a title='author  Timothee Cour &lt;timothee.cour2@gmail.com&gt;  2020-01-31 11:00:05 -0800
committer  GitHub &lt;noreply@github.com&gt;  2020-01-31 20:00:05 +0100

build_all.sh: building csources 5X faster thanks to make -j (#13300)' href='/ahoang/Nim/commit/build_all.sh?h=devel&amp;id=45a5c64c9a01cb198450fa1a7b108710241c8768'>45a5c64c9</a></span> <a title='Blame the previous revision' href='/ahoang/Nim/blame/build_all.sh?h=devel&amp;id=adc52b003960817553aa3481e21a9b335a504e7f'>^</a>
</pre></div><div class='alt'><pre><span class='oid'><a title='author  Timothee Cour &lt;timothee.cour2@gmail.com&gt;  2021-04-23 02:28:42 -0700
committer  GitHub &lt;noreply@github.com&gt;  2021-04-23 11:28:42 +0200

refactor all code that builds csources (#17815)' href='/ahoang/Nim/commit/build_all.sh?h=devel&amp;id=dce0b3b002fcbac716bada039bed4a02eb501744'>dce0b3b00</a></span> <a title='Blame the previous revision' href='/ahoang/Nim/blame/build_all.sh?h=devel&amp;id=dbb053492a3c64236f7e8f9358b9c7f297ba241a'>^</a>

</pre></div><div class='alt'><pre><span class='oid'><a title='author  Timothee Cour &lt;timothee.cour2@gmail.com&gt;  2018-08-08 07:47:17 -0700
committer  Andreas Rumpf &lt;rumpf_a@web.de&gt;  2018-08-08 16:47:17 +0200

add build_all.sh to allow 1-liner to build development version of the compiler (#8546)' href='/ahoang/Nim/commit/build_all.sh?h=devel&amp;id=506418ef539a9142307235c0cd0183f0d7aec749'>506418ef5</a></span> <a title='Blame the previous revision' href='/ahoang/Nim/blame/build_all.sh?h=devel&amp;id=32b62097a2636c5053d842939d34e2a0fa3f9e33'>^</a>



</pre></div><div class='alt'><pre><span class='oid'><a title='author  Timothee Cour &lt;timothee.cour2@gmail.com&gt;  2021-04-23 02:28:42 -0700
committer  GitHub &lt;noreply@github.com&gt;  2021-04-23 11:28:42 +0200

refactor all code that builds csources (#17815)' href='/ahoang/Nim/commit/build_all.sh?h=devel&amp;id=dce0b3b002fcbac716bada039bed4a02eb501744'>dce0b3b00</a></span> <a title='Blame the previous revision' href='/ahoang/Nim/blame/build_all.sh?h=devel&amp;id=dbb053492a3c64236f7e8f9358b9c7f297ba241a'>^</a>

</pre></div><div class='alt'><pre><span class='oid'><a title='author  Timothee Cour &lt;timothee.cour2@gmail.com&gt;  2018-08-08 07:47:17 -0700
committer  Andreas Rumpf &lt;rumpf_a@web.de&gt;  2018-08-08 16:47:17 +0200

add build_all.sh to allow 1-liner to build development version of the compiler (#8546)' href='/ahoang/Nim/commit/build_all.sh?h=devel&amp;id=506418ef539a9142307235c0cd0183f0d7aec749'>506418ef5</a></span> <a title='Blame the previous revision' href='/ahoang/Nim/blame/build_all.sh?h=devel&amp;id=32b62097a2636c5053d842939d34e2a0fa3f9e33'>^</a>
</pre></div><div class='alt'><pre><span class='oid'><a title='author  Ivan Yonchovski &lt;yyoncho@users.noreply.github.com&gt;  2022-08-09 21:04:52 +0300
committer  GitHub &lt;noreply@github.com&gt;  2022-08-09 14:04:52 -0400

Build compiler with --noNimblePath (#20168)' href='/ahoang/Nim/commit/build_all.sh?h=devel&amp;id=ec2bc2a50e268bb08903f1cf83631d93caa34c8f'>ec2bc2a50</a></span> <a title='Blame the previous revision' href='/ahoang/Nim/blame/build_all.sh?h=devel&amp;id=b4157f6772574c18232ff7a663c57ea19804f8f5'>^</a>
</pre></div><div class='alt'><pre><span class='oid'><a title='author  Timothee Cour &lt;timothee.cour2@gmail.com&gt;  2021-04-30 22:24:41 -0700
committer  GitHub &lt;noreply@github.com&gt;  2021-05-01 07:24:41 +0200

reuse config/build_config.txt for all bootstrap scripts (posix + windows + ci); use build_all.bat in 1 CI, fix bug in build_all.bat (#17899)' href='/ahoang/Nim/commit/build_all.sh?h=devel&amp;id=1f1d85bb9c614d93ce38becdcc421dda00264a75'>1f1d85bb9</a></span> <a title='Blame the previous revision' href='/ahoang/Nim/blame/build_all.sh?h=devel&amp;id=abb8a73134597297b2c14567f7f8d72f6b723d24'>^</a>


</pre></div></td>
<td class='linenumbers'><div class='alt'><pre><a id='n1' href='#n1'>1</a>
</pre></div><div class='alt'><pre><a id='n2' href='#n2'>2</a>
</pre></div><div class='alt'><pre><a id='n3' href='#n3'>3</a>
</pre></div><div class='alt'><pre><a id='n4' href='#n4'>4</a>
</pre></div><div class='alt'><pre><a id='n5' href='#n5'>5</a>
<a id='n6' href='#n6'>6</a>
</pre></div><div class='alt'><pre><a id='n7' href='#n7'>7</a>
<a id='n8' href='#n8'>8</a>
<a id='n9' href='#n9'>9</a>
<a id='n10' href='#n10'>10</a>
</pre></div><div class='alt'><pre><a id='n11' href='#n11'>11</a>
<a id='n12' href='#n12'>12</a>
</pre></div><div class='alt'><pre><a id='n13' href='#n13'>13</a>
</pre></div><div class='alt'><pre><a id='n14' href='#n14'>14</a>
</pre></div><div class='alt'><pre><a id='n15' href='#n15'>15</a>
<a id='n16' href='#n16'>16</a>
<a id='n17' href='#n17'>17</a>
</pre></div></td>
<td class='lines'><div><div><div class='alt'><pre>
         </pre></div><div class='alt'><pre>
                                                                      </pre></div><div class='alt'><pre>
 </pre></div><div class='alt'><pre>
                                                                 </pre></div><div class='alt'><pre>

                                </pre></div><div class='alt'><pre>



                                     </pre></div><div class='alt'><pre>

                             </pre></div><div class='alt'><pre>
 </pre></div><div class='alt'><pre>
                                                                                </pre></div><div class='alt'><pre>


                                                                         </pre></div></div><pre><code><style>pre { line-height: 125%; }
td.linenos .normal { color: inherit; background-color: transparent; padding-left: 5px; padding-right: 5px; }
span.linenos { color: inherit; background-color: transparent; padding-left: 5px; padding-right: 5px; }
td.linenos .special { color: #000000; background-color: #ffffc0; padding-left: 5px; padding-right: 5px; }
span.linenos.special { color: #000000; background-color: #ffffc0; padding-left: 5px; padding-right: 5px; }
.highlight .hll { background-color: #ffffcc }
.highlight .c { color: #888888 } /* Comment */
.highlight .err { color: #a61717; background-color: #e3d2d2 } /* Error */
.highlight .k { color: #008800; font-weight: bold } /* Keyword */
.highlight .ch { color: #888888 } /* Comment.Hashbang */
.highlight .cm { color: #888888 } /* Comment.Multiline */
.highlight .cp { color: #cc0000; font-weight: bold } /* Comment.Preproc */
.highlight .cpf { color: #888888 } /* Comment.PreprocFile */
.highlight .c1 { color: #888888 } /* Comment.Single */
.highlight .cs { color: #cc0000; font-weight: bold; background-color: #fff0f0 } /* Comment.Special */
.highlight .gd { color: #000000; background-color: #ffdddd } /* Generic.Deleted */
.highlight .ge { font-style: italic } /* Generic.Emph */
.highlight .ges { font-weight: bold; font-style: italic } /* Generic.EmphStrong */
.highlight .gr { color: #aa0000 } /* Generic.Error */
.highlight .gh { color: #333333 } /* Generic.Heading */
.highlight .gi { color: #000000; background-color: #ddffdd } /* Generic.Inserted */
.highlight .go { color: #888888 } /* Generic.Output */
.highlight .gp { color: #555555 } /* Generic.Prompt */
.highlight .gs { font-weight: bold } /* Generic.Strong */
.highlight .gu { color: #666666 } /* Generic.Subheading */
.highlight .gt { color: #aa0000 } /* Generic.Traceback */
.highlight .kc { color: #008800; font-weight: bold } /* Keyword.Constant */
.highlight .kd { color: #008800; font-weight: bold } /* Keyword.Declaration */
.highlight .kn { color: #008800; font-weight: bold } /* Keyword.Namespace */
.highlight .kp { color: #008800 } /* Keyword.Pseudo */
.highlight .kr { color: #008800; font-weight: bold } /* Keyword.Reserved */
.highlight .kt { color: #888888; font-weight: bold } /* Keyword.Type */
.highlight .m { color: #0000DD; font-weight: bold } /* Literal.Number */
.highlight .s { color: #dd2200; background-color: #fff0f0 } /* Literal.String */
.highlight .na { color: #336699 } /* Name.Attribute */
.highlight .nb { color: #003388 } /* Name.Builtin */
.highlight .nc { color: #bb0066; font-weight: bold } /* Name.Class */
.highlight .no { color: #003366; font-weight: bold } /* Name.Constant */
.highlight .nd { color: #555555 } /* Name.Decorator */
.highlight .ne { color: #bb0066; font-weight: bold } /* Name.Exception */
.highlight .nf { color: #0066bb; font-weight: bold } /* Name.Function */
.highlight .nl { color: #336699; font-style: italic } /* Name.Label */
.highlight .nn { color: #bb0066; font-weight: bold } /* Name.Namespace */
.highlight .py { color: #336699; font-weight: bold } /* Name.Property */
.highlight .nt { color: #bb0066; font-weight: bold } /* Name.Tag */
.highlight .nv { color: #336699 } /* Name.Variable */
.highlight .ow { color: #008800 } /* Operator.Word */
.highlight .w { color: #bbbbbb } /* Text.Whitespace */
.highlight .mb { color: #0000DD; font-weight: bold } /* Literal.Number.Bin */
.highlight .mf { color: #0000DD; font-weight: bold } /* Literal.Number.Float */
.highlight .mh { color: #0000DD; font-weight: bold } /* Literal.Number.Hex */
.highlight .mi { color: #0000DD; font-weight: bold } /* Literal.Number.Integer */
.highlight .mo { color: #0000DD; font-weight: bold } /* Literal.Number.Oct */
.highlight .sa { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Affix */
.highlight .sb { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Backtick */
.highlight .sc { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Char */
.highlight .dl { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Delimiter */
.highlight .sd { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Doc */
.highlight .s2 { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Double */
.highlight .se { color: #0044dd; background-color: #fff0f0 } /* Literal.String.Escape */
.highlight .sh { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Heredoc */
.highlight .si { color: #3333bb; background-color: #fff0f0 } /* Literal.String.Interpol */
.highlight .sx { color: #22bb22; background-color: #f0fff0 } /* Literal.String.Other */
.highlight .sr { color: #008800; background-color: #fff0ff } /* Literal.String.Regex */
.highlight .s1 { color: #dd2200; background-color: #fff0f0 } /* Literal.String.Single */
.highlight .ss { color: #aa6600; background-color: #fff0f0 } /* Literal.String.Symbol */
.highlight .bp { color: #003388 } /* Name.Builtin.Pseudo */
.highlight .fm { color: #0066bb; font-weight: bold } /* Name.Function.Magic */
.highlight .vc { color: #336699 } /* Name.Variable.Class */
.highlight .vg { color: #dd7700 } /* Name.Variable.Global */
.highlight .vi { color: #3333bb } /* Name.Variable.Instance */
.highlight .vm { color: #336699 } /* Name.Variable.Magic */
.highlight .il { color: #0000DD; font-weight: bold } /* Literal.Number.Integer.Long */</style><div class="highlight"><pre><span></span><span class="ch">#!/bin/sh</span>
<span class="c1"># DO NO EDIT DIRECTLY! auto-generated by `nim r tools/ci_generate.nim`</span>

<span class="c1"># build development version of the compiler; can be rerun safely.</span>
<span class="c1"># arguments can be passed, e.g.:</span>
<span class="c1"># CC=gcc ucpu=amd64 uos=darwin</span>

<span class="nb">set</span><span class="w"> </span>-u<span class="w"> </span><span class="c1"># error on undefined variables</span>
<span class="nb">set</span><span class="w"> </span>-e<span class="w"> </span><span class="c1"># exit on first error</span>

.<span class="w"> </span>ci/funs.sh
nimBuildCsourcesIfNeeded<span class="w"> </span><span class="s2">&quot;</span><span class="nv">$@</span><span class="s2">&quot;</span>

echo_run<span class="w"> </span>bin/nim<span class="w"> </span>c<span class="w"> </span>--noNimblePath<span class="w"> </span>--skipUserCfg<span class="w"> </span>--skipParentCfg<span class="w"> </span>--hints:off<span class="w"> </span>koch
echo_run<span class="w"> </span>./koch<span class="w"> </span>boot<span class="w"> </span>-d:release<span class="w"> </span>--skipUserCfg<span class="w"> </span>--skipParentCfg<span class="w"> </span>--hints:off
echo_run<span class="w"> </span>./koch<span class="w"> </span>tools<span class="w"> </span>--skipUserCfg<span class="w"> </span>--skipParentCfg<span class="w"> </span>--hints:off
</pre></div>
</code></pre></div></td>
</tr>
</table>
</div> <!-- class=content -->
<div class='footer'>generated by <a href='https://git.causal.agency/cgit-pink/about/'>cgit-pink 1.4.1-2-gfad0</a> (<a href='https://git-scm.com/'>git 2.36.2.497.gbbea4dcf42</a>) at 2025-01-28 02:02:05 +0000</div>
</div> <!-- id=cgit -->
</body>
</html>
