dos_compilers/Microsoft C v3/INC/ASSERT.H
2024-07-04 11:11:27 -07:00

23 lines
330 B
C

/*
* assert.h
*
* defines the assert macro.
*
* Copyright (C) Microsoft Corporation, 1984
*/
#ifndef NDEBUG
#define assert(exp) { \
if (!(exp)) { \
fprintf(stderr,"Assertion failed: file %s, line %d\n", __FILE__, __LINE__); \
exit(1); \
} \
}
#else
#define assert(exp)
#endif /* NDEBUG */