Re: really bad use of postfix
- From: rvtol+news@xxxxxxxxxxxx (Dr.Ruud)
- Date: Sun, 29 Apr 2007 11:01:47 +0200
Ken Foskey schreef:
Just like to show how NOT to use postfix. I have had a frustrating
day tackling this type of unreadable code.
exec_rqst('stga2k_vps.pl',$FileNameIn) if ($a2kqual[4] eq
"VPS");
exec_rqst('stga2kif.sh',$FileNameIn) if ($a2kqual[4] ne
"VPS");
if ($a2kqual[4] eq "VPS") {
exec_rqst('stga2k_vps.pl',$FileNameIn);
}
else {
exec_rqst('stga2kif.sh',$FileNameIn);
}
It could be generated code, or maybe the coder anticipated
side-effects, like @a2kqual getting adjusted inside exec_rqst().
--
Affijn, Ruud
"Gewoon is een tijger."
.
- References:
- really bad use of postfix
- From: Ken Foskey
- really bad use of postfix
- Prev by Date: Re: hellp improve efficiency
- Next by Date: Re: pure perl replacment for "/usr/bin/file"
- Previous by thread: Re: really bad use of postfix
- Index(es):