GLProgramming.com

home :: about :: development guides :: irc :: forums :: search :: paste :: links :: contribute :: code dump

-> Click here to learn how to get live help <-


New Paste :: Recent Pastes:: No Line Numbers


A Paste by Anonymous
1
 
bool operator<( sorttest& t ) {
        int ind = 0;
        while( ind < 3 && sm[ind] ) {
            switch( sm[ind] ) {
            case INT: 
                if( x == t.x ) break;
                return x < t.x;
            case DOUBLE: 
                if( y == t.y ) break;
                return y < t.y;
            case CHAR: 
                if( g == t.g ) break;
                return g < t.g;
            }
            ++ind;
        }
        return true;
    }