Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10.1 6/24/83; site wjh12.UUCP Path: utzoo!linus!vaxine!wjh12!kendall From: kendall@wjh12.UUCP (Sam Kendall) Newsgroups: net.lang.c Subject: Re: Must useless expressions be evaluated? Message-ID: <334@wjh12.UUCP> Date: Sat, 15-Oct-83 04:52:56 EDT Article-I.D.: wjh12.334 Posted: Sat Oct 15 04:52:56 1983 Date-Received: Sun, 16-Oct-83 14:31:56 EDT References: <187@bbncca.ARPA>, <317@ucbtopaz.CC.Berkeley.ARPA> Organization: Delft Consulting Corp., New York Lines: 18 I think useless expressions must be evaluated, simply because there is no syntactic criterion to determine the uselessness of any expression. For example, (i=j)+something()+k++; is not syntactically different from (i=j)+1+k++; but something() probably has side effects. Well, `something()' is a function call, and `1' isn't. Some (syntactic) operators may have side effects, and others never do. If the result of one of the former isn't used, it must still be evaluated. If the result of one of the latter isn't used, there is no reason to evaluate it. Please, let's drop this topic. Sam Kendall {allegra,ihnp4}!wjh12!kendall Delft Consulting Corp. decvax!genrad!wjh12!kendall