Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

More Anonix Win

Name: Anonymous 2011-08-07 15:31

BEHOLD!



#ifndef __ANONIXWIN_H__
#define __ANONIXWIN_H__

/* Anonix.h - A set of common functions for the Anonix operating system. Copyright: none. Public Domain. Written by Anonymous. United by one. Divided by zero. We do not forgive nor forget. Expect us. */

const int ZERO = 0;

int isequalto(int x,int y){return x==y;}
int isnotequalto(int x,int y){return !isequalto(x, y);}
int islessthan(int x,int y){return x<y;}
int islessthanorequalto(int x,int y){return islessthan(x, y) || isequalto(x, y);}
int isgreaterthan(int x,int y){return x>y;}
int isgreaterthanorequalto(int x,int y){return isgreaterthan(x, y) || isequalto(x, y);}
int isnegative(int x){return islessthan(x, ZERO);}
int ispositive(int x){return isgreaterthanorequalto(x, ZERO);}
int iszero(int x){return isequalto(x, ZERO);}
int isnotzero(int x){return isnotequalto(x, ZERO);}
int dividebyzero(int x){return x/ZERO;}

#endif

Name: Anonymous 2011-08-08 7:42

const int ZERO = 0;
#define ZERO 0


Stop using this shit and use
enum { ZERO };

Name: Anonymous 2011-08-08 8:04

>>24
Out of the three, the preprocessor version is likely to give the fastest compile-time.

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List