home *** CD-ROM | disk | FTP | other *** search
- /* assert.h (c) Copyright 1990 H.Rogers */
-
- #ifndef __ASSERT_H
- #define __ASSERT_H
-
- #ifdef __cplusplus
- extern "C" {
- #endif
-
- #ifdef NDEBUG
- #define assert(x) ()
- #else
- extern int __fail(char *,char *,int);
- #ifdef __STDC__
- #define assert(x) (void)((x) ? 0 : __fail(#x,__FILE__,__LINE__))
- #else
- #define assert(x) (void)((x) ? 0 : __fail("x",__FILE__,__LINE__))
- #endif
- #endif
-
- extern void (assert)(int);
-
- #ifdef __cplusplus
- }
- #endif
-
- #endif
-