Strange compile error
Ron Alexander
rcalex at home.com
Thu May 18 12:44:06 GMT 2000
I just checked CVS to see if this made it in yet. I don't see it. I am busy
porting Samba, and have not had time to learn CVS yet. Would someone who is
knowledgeable please deal with it?
Regards,
Ron
-----Original Message-----
From: samba-technical at samba.org [mailto:samba-technical at samba.org]On
Behalf Of David Collier-Brown
Sent: May 3, 2000 12:47 PM
To: Multiple recipients of list SAMBA-TECHNICAL
Subject: Re: Strange compile error
Ron Alexander wrote:
> SMB_ASSERT(b) ((b)?(void)0: \
> (DEBUG(0,("PANIC: assert failed at %s(%d)\n", \
> __FILE__, __LINE__)), smb_panic("assert failed")))
>
> gives this diagnostic
>
> 067** 1081: A void object is referenced in a context where a valid
> object is required; an object of type int is assumed.
(void) 0 makes the Sun cc cross it's eyes, too.
"foo.c", line 7: operands have incompatible types:
void ":" int
This is a fatal error, as the code generator can't compare
an non-storage type, non-constant to a word... I strongly
suspect this is illegal c, too.
Can some kind soul amend includes/smb.h to change
(b)?(void)0
to
(b)? 0
in the cvs repository?
--dave
--
David Collier-Brown, | Always do right. This will gratify some people
185 Ellerslie Ave., | and astonish the rest. -- Mark Twain
Willowdale, Ontario | //www.oreilly.com/catalog/samba/author.html
Work: (905) 415-2849 Home: (416) 223-8968 Email: davecb at canada.sun.com
More information about the samba-technical
mailing list