diff options
| author | Craig Jennings <c@cjennings.net> | 2025-08-14 22:58:58 -0500 |
|---|---|---|
| committer | Craig Jennings <c@cjennings.net> | 2025-08-14 22:58:58 -0500 |
| commit | 82ba818ff456bcd6d56a06226e3f27e98fbb55c3 (patch) | |
| tree | 158cfc17b2f644a10f063cb546752cfaae12c97f /devdocs/gcc~13/case-ranges.html | |
| parent | 9278ddd4ea1a8b1a4c1edaa8894516e3f48d245b (diff) | |
| download | dotemacs-82ba818ff456bcd6d56a06226e3f27e98fbb55c3.tar.gz dotemacs-82ba818ff456bcd6d56a06226e3f27e98fbb55c3.zip | |
removing all downloaded devdocs files
Diffstat (limited to 'devdocs/gcc~13/case-ranges.html')
| -rw-r--r-- | devdocs/gcc~13/case-ranges.html | 10 |
1 files changed, 0 insertions, 10 deletions
diff --git a/devdocs/gcc~13/case-ranges.html b/devdocs/gcc~13/case-ranges.html deleted file mode 100644 index 9473195d..00000000 --- a/devdocs/gcc~13/case-ranges.html +++ /dev/null @@ -1,10 +0,0 @@ -<div class="section-level-extent" id="Case-Ranges"> <div class="nav-panel"> <p> Next: <a href="cast-to-union" accesskey="n" rel="next">Cast to a Union Type</a>, Previous: <a href="designated-inits" accesskey="p" rel="prev">Designated Initializers</a>, Up: <a href="c-extensions" accesskey="u" rel="up">Extensions to the C Language Family</a> [<a href="index#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="indices" title="Index" rel="index">Index</a>]</p> </div> <h1 class="section" id="Case-Ranges-1"><span>6.30 Case Ranges<a class="copiable-link" href="#Case-Ranges-1"> ΒΆ</a></span></h1> <p>You can specify a range of consecutive values in a single <code class="code">case</code> label, like this: </p> <div class="example smallexample"> <pre class="example-preformatted" data-language="cpp">case <var class="var">low</var> ... <var class="var">high</var>:</pre> -</div> <p>This has the same effect as the proper number of individual <code class="code">case</code> labels, one for each integer value from <var class="var">low</var> to <var class="var">high</var>, inclusive. </p> <p>This feature is especially useful for ranges of ASCII character codes: </p> <div class="example smallexample"> <pre class="example-preformatted" data-language="cpp">case 'A' ... 'Z':</pre> -</div> <p><strong class="strong">Be careful:</strong> Write spaces around the <code class="code">...</code>, for otherwise it may be parsed wrong when you use it with integer values. For example, write this: </p> <div class="example smallexample"> <pre class="example-preformatted" data-language="cpp">case 1 ... 5:</pre> -</div> <p>rather than this: </p> <div class="example smallexample"> <pre class="example-preformatted" data-language="cpp">case 1...5:</pre> -</div> </div><div class="_attribution"> - <p class="_attribution-p"> - © Free Software Foundation<br>Licensed under the GNU Free Documentation License, Version 1.3.<br> - <a href="https://gcc.gnu.org/onlinedocs/gcc-13.1.0/gcc/Case-Ranges.html" class="_attribution-link">https://gcc.gnu.org/onlinedocs/gcc-13.1.0/gcc/Case-Ranges.html</a> - </p> -</div> |
