Skip to content
Snippets Groups Projects
Commit 6e6b888e authored by Paul Sokolovsky's avatar Paul Sokolovsky
Browse files

Add generic MIN()/MAX() functions.

parent e0723497
No related branches found
No related tags found
No related merge requests found
...@@ -10,6 +10,11 @@ ...@@ -10,6 +10,11 @@
typedef unsigned char byte; typedef unsigned char byte;
typedef unsigned int uint; typedef unsigned int uint;
/** generic ops *************************************************/
#define MIN(x, y) ((x) < (y) ? (x) : (y))
#define MAX(x, y) ((x) > (y) ? (x) : (y))
/** memomry allocation ******************************************/ /** memomry allocation ******************************************/
// TODO make a lazy m_renew that can increase by a smaller amount than requested (but by at least 1 more element) // TODO make a lazy m_renew that can increase by a smaller amount than requested (but by at least 1 more element)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment