Changeset 710d0c8c for libcfa/src
- Timestamp:
- Apr 15, 2024, 9:40:35 PM (8 months ago)
- Branches:
- master
- Children:
- 7aa209e7, fbe3f03
- Parents:
- fb2e916
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
libcfa/src/stdlib.hfa
rfb2e916 r710d0c8c 10 10 // Created On : Thu Jan 28 17:12:35 2016 11 11 // Last Modified By : Peter A. Buhr 12 // Last Modified On : Fri Apr 12 07:39:15202413 // Update Count : 81 212 // Last Modified On : Mon Apr 15 10:51:38 2024 13 // Update Count : 815 14 14 // 15 15 … … 64 64 } // calloc 65 65 66 T * resize( T * ptr, size_t size ) { // CFA resize , eliminate return-type cast66 T * resize( T * ptr, size_t size ) { // CFA resize 67 67 if ( _Alignof(T) <= libAlign() ) return (T *)resize( (void *)ptr, size ); // CFA resize 68 68 else return (T *)resize( (void *)ptr, _Alignof(T), size ); // CFA resize 69 69 } // resize 70 70 71 T * realloc( T * ptr, size_t size ) { // CFA realloc , eliminate return-type cast71 T * realloc( T * ptr, size_t size ) { // CFA realloc 72 72 if ( _Alignof(T) <= libAlign() ) return (T *)realloc( (void *)ptr, size ); // C realloc 73 73 else return (T *)realloc( (void *)ptr, _Alignof(T), size ); // CFA realloc 74 } // realloc 75 76 T * reallocarray( T * ptr, size_t dim ) { // CFA reallocarray 77 if ( _Alignof(T) <= libAlign() ) return (T *)reallocarray( (void *)ptr, dim, sizeof(T) ); // C reallocarray 78 else return (T *)reallocarray( (void *)ptr, _Alignof(T), dim ); // CFA reallocarray 74 79 } // realloc 75 80
Note: See TracChangeset
for help on using the changeset viewer.