comp.lang.ada
 help / color / mirror / Atom feed
From: "Yannick Duchêne (Hibou57)" <yannick_duchene@yahoo.fr>
Subject: Re: Does Ada need a 'secure coding standard' as well?
Date: Sat, 28 May 2011 21:45:15 +0200
Date: 2011-05-28T21:45:15+02:00	[thread overview]
Message-ID: <op.vv7ihpetule2fv@douda-yannick> (raw)
In-Reply-To: irrj0h$6cb$1@speranza.aioe.org

Le Sat, 28 May 2011 21:38:56 +0200, Nasser M. Abbasi <nma@12000.org> a  
écrit:
> 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-switch-support/

A good idea, but they still did not removed the requirement of an explicit  
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");
    }


-- 
“Syntactic sugar causes cancer of the semi-colons.”  [Epigrams on  
Programming — Alan J. — P. Yale University]
“Structured Programming supports the law of the excluded muddle.” [Idem]
“c++; /* this makes c bigger but returns the old value */” [Anonymous]



  reply	other threads:[~2011-05-28 19:45 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-05-28 18:53 Does Ada need a 'secure coding standard' as well? Nasser M. Abbasi
2011-05-28 19:06 ` Yannick Duchêne (Hibou57)
2011-05-28 19:38   ` Nasser M. Abbasi
2011-05-28 19:45     ` Yannick Duchêne (Hibou57) [this message]
2011-05-28 19:32 ` Ludovic Brenta
2011-05-31 16:59   ` Simon Clubley
2011-05-31 17:51     ` AdaMagica
2011-05-31 18:54       ` Simon Clubley
2011-05-28 21:37 ` Simon Wright
2011-05-29 13:29   ` Mark_Ngbapai
2011-05-29 13:58     ` Simon Wright
2011-05-29 14:04 ` Yannick Duchêne (Hibou57)
2011-05-29 14:05   ` Yannick Duchêne (Hibou57)
2011-05-30 10:25   ` J-P. Rosen
2011-05-29 15:23 ` Maciej Sobczak
2011-05-29 15:53   ` Yannick Duchêne (Hibou57)
2011-05-30 10:27     ` J-P. Rosen
2011-05-29 21:03   ` Florian Weimer
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox