taia_less.c (311B)
1 /* Public domain. */ 2 3 #include "taia.h" 4 5 /* XXX: breaks tai encapsulation */ 6 7 int taia_less(const struct taia *t,const struct taia *u) 8 { 9 if (t->sec.x < u->sec.x) return 1; 10 if (t->sec.x > u->sec.x) return 0; 11 if (t->nano < u->nano) return 1; 12 if (t->nano > u->nano) return 0; 13 return t->atto < u->atto; 14 }