Listing 3: Converting the digit into its equivalent character value

/* /////////////////////////////////////////////////////////////
 *
 * ...
 *
 * Extract from stlsoft_integer_to_string.h
 *
 * www:        http://www.synesis.com.au/stlsoft
 *             http://www.stlsoft.org/
 *
 * Copyright (C) 2002, Synesis Software Pty Ltd.
 * (Licensed under the Synesis Software Standard Source License:
 *  http://www.synesis.com.au/licenses/ssssl.html)
 *
 * ...
 *
 * ////////////////////////////////////////////////////////// */

...

template <ss_typename_param_k C>
inline const C *get_digit_character()
{
    static const C  s_characters[19] = 
    {
            '9'
        ,   '8'
        ,   '7'
        ,   '6'
        ,   '5'
        ,   '4'
        ,   '3'
        ,   '2'
        ,   '1'
        ,   '0'
        ,   '1'
        ,   '2'
        ,   '3'
        ,   '4'
        ,   '5'
        ,   '6'
        ,   '7'
        ,   '8'
        ,   '9'
    };
    static const C  *s_mid  =   s_characters + 9;

    return s_mid;
}
— End of Listing —