You might be amused to know that in one set of programming standards
(for Java) presented to the SACC, it was required that the K&R
indentation style be used. My reaction was "Ugh! Why?" But
apparently some people feel that it makes C like code much more
readable than the ANSI C style.
I'm not a big fan of using braces to delimit blocks (I prefer the use
of "begin" and "end", as in Pascal, but I've just never been able to
get used to "fi", "od" and "esac", which are used in some other Algol-
like languages). Indentation based languages like MUMPS, Python and
Haskell are problematic, too. One technical issue is that they make
scanning a lot more complicated, but I've never really felt like they
were very programmer-friendly either. (In the case of Python, IDLE
makes the syntax reasonably tolerable.)
===
Gregory Woodhouse
[EMAIL PROTECTED]
"The whole of science is nothing more than a refinement
of everyday thinking." -- Albert Einstein
On Sep 14, 2005, at 6:42 PM, Chris Richardson wrote:
Kevin;
I feel the same way about curley braces (in C and other legitimate
languages). I find it so strange to see which closing brace goes
with which
opening brace.
I have programmed in FORTRAN and APL before MUMPS and was very
happy to
NOT use the GOTO in MUMPS. Now the exit on condition can be
abbomplished
with a consistant set of exit actions by installing a dot block
which allows
for the negative/positive actions to decide an action and then to
exit. It
is what I call a herring bone filter. Here is a simplified form;
EVALU8(A,B) ; Evaluate the string passed as A, contition returned in B
N E,X
S B=$G(B)
S E=$G(A)
S X="999;Unidentified Error: "_E
D
. I A?1.N S X="0;Numeric: "_E Q
. I A?1.AN S X="0;AlphaNumeric: "_E Q
. ; As many conditions as needed go here, but when the situation is
found, exit the block.
. ; Else was a precondition
.QUIT
S:'X B="Success"
QUIT X
; ==============
-------------------------------------------------------
SF.Net email is sponsored by:
Tame your development challenges with Apache's Geronimo App Server. Download
it for free - -and be entered to win a 42" plasma tv or your very own
Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php
_______________________________________________
Hardhats-members mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/hardhats-members