Re: The meaning of 'sugar' [Forked from Re: Why do we have ipairs?]
[
Date Prev][
Date Next][
Thread Prev][
Thread Next]
[
Date Index]
[
Thread Index]
- Subject: Re: The meaning of 'sugar' [Forked from Re: Why do we have ipairs?]
- From: Roberto Ierusalimschy <roberto@...>
- Date: 2014年6月11日 11:57:31 -0300
> Perhaps what you are saying is that as there are no symbolic
> constants in Lua, it is not possible to generate optimized switch
> statements for all but the simplest scenario where the switch cases
> are literals?
Exactly. (These cases are not only simplest, but usually considered bad
code. If we add a switch optimized only for literals, its impact in code
standards for Lua would be a tragedy...)
-- Roberto