httpd-apreq-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Joe Schaefer <...@sunstarsys.com>
Subject Re: [apreq-2] conditionals
Date Sat, 19 Apr 2003 23:38:00 GMT
Randy Kobes <randy@theoryx5.uwinnipeg.ca> writes:

[...]

> Ah - thanks for pointing that out. The error I'm getting with
> something like
>     (a > 0) ? c : d = 3;
> or
>     (a > 0 ? c : d) = 3;
> is
>    '=' : left operand must be l-value
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^

OOPS.  My mistake :-(

> What does work is 
>     (a > 0) ? (c=3) : (d=3);

Cool, but I'd rather see that written this way

  if (a > 0)
      c = 3;
  else
      d = 3;


I'd rather convert the bogus ?: lines to that format.
Randy, if you agree that this is better, please make
the commit.

Actually, all the suggestions you made today are fine
with me except for the strcasecmp one.  I put the t->cmp
(mis)feature in way before the tables were implemented, and 
now I'd rather see it pulled out entirely.  IMO we should 
just use strcasecmp whereever t->cmp is used in the 
apreq_tables.c source. 

-- 
Joe Schaefer

Mime
View raw message