[OT] Re: The Is Operator

Jarrett Billingsley kb3ctd2 at yahoo.com
Wed Oct 3 05:58:41 PDT 2007


"Robert Fraser" <fraserofhenight at gmail.com> wrote in message 
news:fdvg0m$2c3e$1 at digitalmars.com...
> From some experience in Perl, I can say unless(P) is slightly clearer than 
> if(!P) and until(P) is slightly clearer than while(!P) ... in most cases. 
> I'm not arguing it should be added to D (esp. since if there are multiple 
> ways to express something, stuff can get confusing), but they _do_ make 
> code just that much easier to read.
>
> On that note, I'm also a slight fan of the postfix notation for simple ifs 
> (i.e. something like "a = b if b;" or "file.read() while 
> file.hasMoreBytes();"), but it makes parsing a *****.

Course you also get people who think it's "cute" to do something like

while(someCondition)
{
    .....
    3 pages of code...
    .....
}
if(someOtherCondition) 





More information about the Digitalmars-d mailing list