Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10.2 9/5/84; site cvl.UUCP Path: utzoo!linus!philabs!cmcl2!seismo!umcp-cs!cvl!dno From: dno@cvl.UUCP (David Oskard) Newsgroups: net.unix-wizards Subject: Sun C compiler bug Message-ID: <666@cvl.UUCP> Date: Fri, 26-Jul-85 12:34:04 EDT Article-I.D.: cvl.666 Posted: Fri Jul 26 12:34:04 1985 Date-Received: Sun, 28-Jul-85 08:08:54 EDT Distribution: net Organization: Computer Vision Lab, U. of Maryland, College Park Lines: 25 [Eat my line!] On our Sun, the following C code gives an "illegal address" error: if (*bp++) ... where bp is float *bp = SOMEARRAY[WHATEVER]; It has something to do with the evaluation of the conditional expression (it works fine in regular expressions). I haven't tried to reproduce it with other variable types, but it may or may not be type independent. Has anybody out there fixed this bug? Replies would be greatly appreciated. Please respond by mail. I'll post the results. Incidentally, the bug can be avoided by doing if (*bp) { .... } bp++; David Oskard seismo!rlgvax!cvl!dno dno@cvl.arpa University of Maryland Center For Automation Research