Re: 'Unknown' and three-valued logic (was: Example where Euphoria ...)
- Posted by Rom <kjehas at frisurf.no> Nov 24, 2002
- 457 views
It is all C's fault. I remember my first Toolswork C-compiler. It was absolutely a = disasterous experience for someone who's only experience was with Basic = interpreters. First the syntax errors.... then, if the program was not = right, looose pointers and that kind of things, causeing the program to = go beserk and easily crashed whole computer. I am wondering how much C has shaped other programming languages, too? = When other languages are created using C, then the "*" operator are most = likely to be a C call? And the same goes for the relational operators ( = =3D,>...) so that the other languages created with C are likely to = inherit the same weaknesses as C? And C does not reserve any flag for a = variable being instanciated or not, it just uses whatever it find at = that memory address, there is no checking about the variable has been = set or not (that is very speedy ... which the designers of C wanted it = to be). So basicly, it the program is not right, then output will be rubbish = values... not nil values. When you tell a C program to multiply to = variables that are not set, then the result is rubbish... and there is = no obvious way to test if the values are rubbish or not. When C evaluates a conditional statements upon a boolean value .... that = is not set ... then C branches in the wrong direction ...(and there is = no obvious way to test if current branch is caused by rubbish = branchin)... instead of branching in the direction it should have gone = when branching is unsolved. It could all have been different... if there had been a nil flag for all = variables .. then all the compilers created with C would also have been = different ... because if C had been different, then the other compilers = would have inherited a lot of that behavior ... the best of it, = hopefully? It is all C's fault, behaving like an idiot. Regards Rom