assert.h

Go to the documentation of this file.
00001 /*
00002  * PSP Software Development Kit - http://www.pspdev.org
00003  * -----------------------------------------------------------------------
00004  * Licensed under the BSD license, see LICENSE in PSPSDK root for details.
00005  *
00006  * assert.h
00007  *
00008  * Copyright (c) 2002-2004 PS2DEV
00009  * Copyright (c) 2005 Marcus R. Brown <mrbrown@ocgnet.org>
00010  * Copyright (c) 2005 James Forshaw <tyranid@gmail.com>
00011  * Copyright (c) 2005 John Kelley <ps2dev@kelley.ca>
00012  *
00013  * $Id: assert.h 1095 2005-09-27 21:02:16Z jim $
00014  */
00015 #ifndef __ASSERT_H__
00016 #define __ASSERT_H__
00017 
00018 #include <pspkernel.h>
00019 #include <stdio.h>
00020 
00021 #ifdef NDEBUG
00022 #define assert(cond)
00023 #else
00024 #ifdef __cplusplus
00025 extern "C" {
00026 #endif
00027     int __assert_fail (const char *assertion, const char *file, unsigned int line) __attribute__((noreturn));
00028 #ifdef __cplusplus
00029 }
00030 #endif
00031 #define assert(cond) (void)((cond)?0:__assert_fail(#cond, __FILE__, __LINE__))
00032 #endif
00033 
00034 #endif

Generated on Tue Jul 24 15:21:23 2007 for PSPSDK-Rev2272 by  doxygen 1.5.2