Subject: Re: [lojban] C question: How to or strings and get a string?

From: John Cowan <[email-masked]>
Date: Wed, 22 Jan 2003 23:02:02 -0500 (EST)

Pierre Abbat scripsit:

> monmapti returns NULL if it didn't match or a pointer to the first character 
> after the matching string if it does. is3rafsi is supposed to do the same, 
> but instead it returns 1, which confuses isslinkuhi, which then calls 
> is3rafsi(1) and crashes. 

That is because the value of || is always 0 or 1.

Have you proved that these macros are necessary to sufficiently speedy
performance? If you haven't, replace them with functions. Premature
optimization is the root of all evil.

-- 
John Cowan [email-masked] www.reutershealth.com www.ccil.org/~cowan
Assent may be registered by a signature, a handshake, or a click of a computer
mouse transmitted across the invisible ether of the Internet. Formality
is not a requisite; any sign, symbol or action, or even willful inaction,
as long as it is unequivocally referable to the promise, may create a contract.
--_Specht v. Netscape_