T should be a POD type. Conventional binary comparision operators, > and <, must be defined for objects of type T, and a function mostpos must be overloaded with the entry point
void mostpos(T* res) ;
which sets *res to the largest allowed value of type T. The Adlib header files define mostpos for all the standard arithmetic types of C++, so these types satisfy all the requirements for T.