[DGD]1.1.52

Gregory D Lewis glewis at maths.adelaide.edu.au
Sun Mar 14 03:03:47 CET 1999


> I'd like to stop here and request feedback. It is my opinion that the
> introduction of a boolean type would improve clarity in code. I also think
> that a certain amount of strictness in a programming language such as LPC
> is solely positive. Unfortunately, I feel like I'm having a hard time
> formulating my thoughts on the subject. Can anyone tell me what I'm trying
> to say? 

Well...I can't tell you what you're trying to say since only you know :).

I do however believe a boolean type adds greatly to the clarity of a language.
A variable or function of this type has made one aspect of its existence
abundantly clear to anyone reading the code, it is for the use of a true
or false value.  To use an int instead you've immediately added a degree of
obfuscation to your code, variable/function naming schemes notwithstanding.
Certainly people can (and have) done things such as "#define TRUE 1" and the
like, but these really boil down to somewhat kludgey workarounds (IMO).

For compatibility concerns, one can always introduce the boolean type in much
the same way as C++, where it may cast to a 0 or 1 as an int.

-- 
Greg Lewis                              Applied Maths Department
Email : glewis at maths.adelaide.edu.au    University of Adelaide
--
IBM had a PL/I,
	Its syntax worse than JOSS;
And everywhere this language went,
	It was a total loss.

List config page:  http://list.imaginary.com/mailman/listinfo/dgd



More information about the DGD mailing list