comp.lang.c
[Top] [All Lists]

Re: case labels

Subject: Re: case labels
From: jacob navia
Date: Fri, 28 Mar 2008 19:36:19 +0100
Newsgroups: comp.lang.c


lawrence.jones@xxxxxxxxxxx wrote:
Keith Thompson <kst-u@xxxxxxx> wrote:
Having said that, there's nothing forbidding a compiler from treating
a switch statement like an if/else chain anyway (and it will probably
have to do something like that if the range of cases is very large).

Indeed, most compilers have a number of different strategies for
implementing switch statements that they choose from based on things
like the number of cases, their range, and density.


Yes. Lcc-win will produce a if/else if the number of case
is less equal to 3.


-Larry Jones

When I want an editorial, I'll ASK for it! -- Calvin


--
jacob navia
jacob at jacob point remcomp point fr
logiciels/informatique
http://www.cs.virginia.edu/~lcc-win32

<Prev in Thread] Current Thread [Next in Thread>
Privacy Policy