Changeset 726b748


Ignore:
Timestamp:
Nov 12, 2020, 11:40:42 PM (3 years ago)
Author:
Peter A. Buhr <pabuhr@…>
Branches:
ADT, arm-eh, ast-experimental, enum, forall-pointer-decay, jacob/cs343-translation, master, new-ast-unique-expr, pthread-emulation, qualifiedEnum
Children:
26ceca1, a0ba5e6
Parents:
c1076a2f (diff), 9139540 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
Message:

Merge branch 'master' of plg.uwaterloo.ca:software/cfa/cfa-cc

Files:
2 edited

Legend:

Unmodified
Added
Removed
  • libcfa/src/stdlib.hfa

    rc1076a2f r726b748  
    1010// Created On       : Thu Jan 28 17:12:35 2016
    1111// Last Modified By : Peter A. Buhr
    12 // Last Modified On : Thu Nov 12 08:12:08 2020
    13 // Update Count     : 515
     12// Last Modified On : Thu Nov 12 20:58:48 2020
     13// Update Count     : 520
    1414//
    1515
     
    101101                return (T *)pvalloc( sizeof(T) );                               // C pvalloc
    102102        } // pvalloc
    103 
    104         void free( T * addr ) {
    105                 free( (void *) addr );                                                  // C free
    106         } // free
    107103} // distribution
    108104
     
    260256static inline forall( dtype T, ttype TT | { void free( TT ); } )
    261257void free( T * addr, TT rest ) {
    262         free( addr );
     258        free( ( void *)addr );                                                          // use C free
    263259        free( rest );
    264260} // free
  • tests/malloc.cfa

    rc1076a2f r726b748  
    319319        free(ip);
    320320
    321         free( (void *) 0p ); // sanity check
     321        free( 0p ); // sanity check
    322322        free( NULL ); // sanity check
    323323
Note: See TracChangeset for help on using the changeset viewer.