%% options copyright owner = Dirk Krause copyright year = 2015-xxxx license = bsd %% header /** @file Comparison between signed and unsigned character. */ #ifdef __cplusplus extern "C" { #endif /** Compare signed and unsigned char. @param s Signed char. @param u Unsigned char. @return 1 if s>u, 0 if s==u, -1 if s s) { back = -1; } else { if ((unsigned char)s < u) { back = -1; } else { if ((unsigned char)s > u) { back = 1; } } } return back; }