QNX assert command

Hi,

I’m looking on the defenition of the ‘assert’ command in the assert.h file.
I can’t figure out what is the meaning of the first parameter.

Any ideas?

\


Benzy Gabay
R&D
Everbee Wireless
mailto:bgabay@everbee.com
tel. +972-9-956-0135
fax. +972-9-955-9654

Ben Gabay <bgabay@everbee.com> wrote:

Hi,

I’m looking on the defenition of the ‘assert’ command in the assert.h file.
I can’t figure out what is the meaning of the first parameter.

assert() takes one parameter and only one parameter – the parameter
happens to be something that returns true or false, generally some
conditional.

e.g.
/* x can never be 0 */
assert( (x != 0 ) );
y = 5/x;

-David

QNX Training Services
dagibbs@qnx.com