From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,FREEMAIL_FROM autolearn=ham autolearn_force=no version=3.4.4 X-Google-Thread: 103376,bb14f1c1986544fb X-Google-NewGroupId: yes X-Google-Attributes: gida07f3367d7,domainid0,public,usenet X-Google-Language: ENGLISH,UTF8 Path: g2news2.google.com!news2.google.com!news.glorb.com!selfless.tophat.at!aioe.org!.POSTED!not-for-mail From: =?utf-8?Q?Yannick_Duch=C3=AAne_=28Hibou57?= =?utf-8?Q?=29?= Newsgroups: comp.lang.ada Subject: Re: Does Ada need a 'secure coding standard' as well? Date: Sat, 28 May 2011 21:45:15 +0200 Organization: Ada @ Home Message-ID: References: NNTP-Posting-Host: 0wEclEfVa5yTOGBZFIm9ZQ.user.speranza.aioe.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed; delsp=yes Content-Transfer-Encoding: Quoted-Printable X-Complaints-To: abuse@aioe.org User-Agent: Opera Mail/11.01 (Linux) X-Notice: Filtered by postfilter v. 0.8.2 Xref: g2news2.google.com comp.lang.ada:20515 Date: 2011-05-28T21:45:15+02:00 List-Id: Le Sat, 28 May 2011 21:38:56 +0200, Nasser M. Abbasi a = =C3=A9crit: > The funny thing, is that Java 7 just added a switch on string ! > > http://www.vineetmanohar.com/2011/03/new-java-7-feature-string-in-swit= ch-support/ A good idea, but they still did not removed the requirement of an explic= it = Break and the end of each case, so that is still not a real Switch, that= 's = still a Goto. switch (color) { case "red": System.out.println("Color is Red"); break; case "green": System.out.println("Color is Green"); break; default: System.out.println("Color not found"); } -- = =E2=80=9CSyntactic sugar causes cancer of the semi-colons.=E2=80=9D [Ep= igrams on = Programming =E2=80=94 Alan J. =E2=80=94 P. Yale University] =E2=80=9CStructured Programming supports the law of the excluded muddle.= =E2=80=9D [Idem] =E2=80=9Cc++; /* this makes c bigger but returns the old value */=E2=80=9D= [Anonymous]