Bill Allombert on Tue, 5 Dec 2000 20:03:19 +0100 |
[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]
Re: inequalities |
On Tue, Dec 05, 2000 at 10:51:42AM -0800, Carl R. Witty wrote: > I don't think that > (a<b)<c > should necessarily give a warning; I think it would be nice if > a<b<c > gave a warning. > > Yes, I realize that it may be annoying to tell these cases apart. > > Carl Witty > The problem is that the (yacc) parser eats up the parens, so after parsing, there is no way to tell the difference. However, a<b is (in the compiler) of type boolean, and it can issue a warning if a boolean is used in a comparaison. Bill.