+ 1).toUnsigned(8);
</code></pre>
<p><code>q</code> will count from <code>0</code> up to <code>255</code> and then wrap around to <code>0</code>.</p>
<p>If the input fits in <code>width</code> bits without truncation, the result is the
same as the input.  The minimum width needed to avoid truncation of <code>x</code> is
given by <code>x.bitLength</code>, i.e.</p>
<pre class="language-dart"><code>x == x.toUnsigned(x.bitLength);
</code></pre>
    </section>
    
    <section class="summary source-code" id="so