// // Cforall Version 1.0.0 Copyright (C) 2016 University of Waterloo // // The contents of this file are covered under the licence agreement in the // file "LICENCE" distributed with Cforall. // // stdlib -- // // Author : Peter A. Buhr // Created On : Thu Jan 28 17:12:35 2016 // Last Modified By : Peter A. Buhr // Last Modified On : Fri Feb 5 15:21:18 2016 // Update Count : 61 // //--------------------------------------- extern "C" { #include // size_t } // extern "C" forall( type T ) T * memset( T * ptr, unsigned char fill ); // use default value '\0' for fill forall( type T ) T * memset( T * ptr ); // remove when default value available forall( type T ) T * malloc( void ); forall( type T ) T * malloc( char fill ); forall( type T ) T * malloc( size_t size ); forall( type T ) T * malloc( T * ptr, size_t size ); forall( type T ) T * malloc( T * ptr, size_t size, unsigned char fill ); forall( type T ) T * calloc( size_t size ); forall( type T ) T * realloc( T * ptr, size_t size ); forall( type T ) T * realloc( T * ptr, size_t size, unsigned char fill ); forall( type T ) T * aligned_alloc( size_t alignment ); forall( type T ) T * memalign( size_t alignment ); // deprecated forall( type T ) int posix_memalign( T ** ptr, size_t alignment ); //--------------------------------------- int ato( const char * ptr ); unsigned int ato( const char * ptr ); long int ato( const char * ptr ); unsigned long int ato( const char * ptr ); long long int ato( const char * ptr ); unsigned long long int ato( const char * ptr ); float ato( const char * ptr ); double ato( const char * ptr ); long double ato( const char * ptr ); float _Complex ato( const char * ptr ); double _Complex ato( const char * ptr ); long double _Complex ato( const char * ptr ); int strto( const char * sptr, char ** eptr, int base ); unsigned int strto( const char * sptr, char ** eptr, int base ); long int strto( const char * sptr, char ** eptr, int base ); unsigned long int strto( const char * sptr, char ** eptr, int base ); long long int strto( const char * sptr, char ** eptr, int base ); unsigned long long int strto( const char * sptr, char ** eptr, int base ); float strto( const char * sptr, char ** eptr ); double strto( const char * sptr, char ** eptr ); long double strto( const char * sptr, char ** eptr ); float _Complex strto( const char * sptr, char ** eptr ); double _Complex strto( const char * sptr, char ** eptr ); long double _Complex strto( const char * sptr, char ** eptr ); //--------------------------------------- forall( type T | { int ??( T, T ); } ) T max( const T t1, const T t2 ); forall( type T ) void swap( T * t1, T * t2 ); // Local Variables: // // mode: c // // tab-width: 4 // // End: //