//----------------------------------------------------------------------------// // GNU GPL OS/K // // // // Authors: spectral` // // NeoX // // // // Desc: Kaleid string library // //----------------------------------------------------------------------------// #ifndef _KALCOMM_STRING_H #define _KALCOMM_STRING_H #ifndef _KALCOMM_COMMON_H # include #endif //------------------------------------------// // Memory management utilitaries // //------------------------------------------// #ifndef _OSK_SOURCE # define memcpy _osk_memcpy # define memset _osk_memset # define memcmp _osk_memcmp # define memzero _osk_memzero #endif void *memset(void *, int, size_t); void *memzero(void *, size_t); //------------------------------------------// // String manipulation utilitaries // //------------------------------------------// #ifndef _OSK_SOURCE # define strlen _osk_strlen # define strcpy _osk_strcpy # define strncpy _osk_strncpy # define strrev _osk_strrev # define reverse _osk_reverse # define sprintf _osk_sprintf # define snprintf _osk_snprintf # define vsprintf _osk_vsprintf # define vsnprintf _osk_vsnprintf #endif size_t strlen(const char *); char *strcpy(char *, const char *); char *strncpy(char *, const char *, size_t); char *strrev(char *dest, const char *src); char *reverse(char *); int sprintf(char *, const char *, ...); int snprintf(char *, size_t, const char *, ...); int vsprintf(char *, const char *, va_list); int vsnprintf(char *, size_t, const char *, va_list); //------------------------------------------// // Type conversion utilities // //------------------------------------------// #ifndef _OSK_SOURCE # define itoa _osk_itoa # define atoi _osk_atoi #endif char *itoa(int, char *, int); //------------------------------------------// // End of kaleid/common/stdlib.h // //------------------------------------------// #endif