fx9860g and fxcg50 2D math rendering library with support for TeX syntax.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

26 lines
478 B

//---
// defs: Just generic definitions
//---
#ifndef DEFS_H
#define DEFS_H
/* uint type for bit fields */
typedef unsigned int uint;
/* min(), max(): But don't duplicate side-effects */
#define min(a, b) ({ \
__auto_type _a = (a); \
__auto_type _b = (b); \
_a < _b ? _a : _b; \
})
#define max(a, b) ({ \
__auto_type _a = (a); \
__auto_type _b = (b); \
_a > _b ? _a : _b; \
})
/* Attributes */
#define TEX_UNUSED __attribute__((unused))
#endif /* DEFS_H */