Glibc common: Difference between revisions
Jump to navigation
Jump to search
(Created page with "== Overview == GNU C library 내용 정리 == assert.h == 컴파일 시, -DNDEBUG 옵션을 함께 사용하면 assert() 관련 함수들이 동작하지 않는다. 조심할...") |
(No difference)
|
Revision as of 22:27, 11 July 2016
Overview
GNU C library 내용 정리
assert.h
컴파일 시, -DNDEBUG 옵션을 함께 사용하면 assert() 관련 함수들이 동작하지 않는다. 조심할 것.
/* void assert (int expression); If NDEBUG is defined, do nothing. If not, and EXPRESSION is zero, print an error message and abort. */
assert()
<source lang=c>
- include <assert.h>
void assert(scalar expression); </source> Expression 의 내용이 false 일 경우, 코어 덤프 생성 후, 프로그램을 종료한다.