Revision 9e0ef580de526e6a31df5ded03b4e917e14db727 authored by a1ex on 06 June 2011, 20:52:56 UTC, committed by a1ex on 06 June 2011, 20:52:56 UTC
1 parent 46f9560
Raw File
pymite-helpers.h
/** \file
 * PyMite wrappers
 */
#ifndef _pymite_h_
#define _pymite_h_

#include "pm.h"

#define PM_ARG_INT(num) \
	( { \
		pPmObj_t pn = NATIVE_GET_LOCAL(num); \
		if( OBJ_GET_TYPE(pn) != OBJ_TYPE_INT ) \
		{ \
			PM_RAISE( retval, PM_RET_EX_TYPE ); \
			return retval; \
		} \
		((pPmInt_t)pn)->val; \
	} )
		
#endif
back to top