else in csh
Stephen [Steve] R Smoot
smoot at woodstock.berkeley.edu
Fri May 24 12:50:31 AEST 1991
Can someone explain to me why the following is valid in csh?
It seems invalid according to the man page (though treating the
commands listing as a formal grammar is going a tad far, I know),
but runs without error:
-------------------------------------------------------------------------------
#!/bin/csh -f
else
echo "No, I dont get printed, never get executed"
endif
-------------------------------------------------------------------------------
It makes invalid nested if statements easier to write than most
languages...
-s
More information about the Comp.unix.shell
mailing list