tcsh's conditionals

[prev] [thread] [next] [lurker] [Date index for 2006/07/19]

From: Simon Wistow
Subject: tcsh's conditionals
Date: 17:42 on 19 Jul 2006
Oh tcsh - so much to despise about you my little hate dumpling stuffed 
with loathsomeness.  

How we could while away the evenings talking about your little
pecadillos. I can picture it now - you'd be on the floor cowering and
I'd be standing over you, repeatedly hitting you using a bat with a
rusty nail through it, cackling whilst your screams for forgiveness
became slowly muffled by your own sobbing.

Good times. Good times.

But, such pleasurable evenings will have to wait because we need to have 
a talk about your conditional statements, you and I. No, no, there's no 
need to be modest. Don't be shy. I merely want to ask you which of these 
is the correct syntax ...


     if ($foo) then
          echo "foo"
     elsif ($bar) then
          echo "bar"
     endif

or

     if ($foo) then
          echo "foo"
     else if ($bar) then
          echo "bar"
     endif


Hmm. The second choice you say? My, my, my. That *is* interesting 
because, you see, the first choice doesn't provoke a compile error. No, 
no, no such niceties are for weak minded, lily livered, frankly pinko, 
leftie WIMP programmers. So gauche. So ... recherche.

A real man's language would compile the first syntax fine and then ... 
oh, do excuse me, I'm chuckling just thinking about it ... and then
silently ignore it. Unless of course there's a 'else' statement which
will, in that case, *always* get run. 

Since it's the default case it will probably go undetected for YEARS 
until some poor schmoe is asked to find why a certain option isn't 
working on some script left lying around. Oh how he'll clutch his sides 
with mirth, wipe a tear of glee from his eyes and then sink back in his 
chair, plotty gruesome revenge on you.

Tssk, I ramble. So indulgent of me to take up your precious time when it 
could be more productively spent making someone else's life a misery. 
Accept my apologies, please.

Until we meet again, dear tcsh. I'm sure you'll recognise me - I'll be 
the one skull fucking you to death with the severed arms of your 
creators. I may be covered in blood and crying bloody murder.

Yours,

Simon


Generated at 20:01 on 19 Jul 2006 by mariachi 0.52