From e0e2d3444670d4a368f632cd34d0356472fa489e Mon Sep 17 00:00:00 2001 From: Sven Verdoolaege Date: Wed, 25 Feb 2009 21:00:47 +0100 Subject: [PATCH] add isl_calloc_type --- include/isl_ctx.h.in | 2 ++ 1 file changed, 2 insertions(+) diff --git a/include/isl_ctx.h.in b/include/isl_ctx.h.in index 9f8da8c..112b27f 100644 --- a/include/isl_ctx.h.in +++ b/include/isl_ctx.h.in @@ -65,8 +65,10 @@ struct isl_ctx { #define F_ISSET(p, f) FL_ISSET((p)->flags, f) #define isl_alloc(ctx,type,size) (type *)malloc(size) +#define isl_calloc(ctx,type,size) (type *)calloc(1, size) #define isl_realloc(ctx,ptr,type,size) (type *)realloc(ptr,size) #define isl_alloc_type(ctx,type) isl_alloc(ctx,type,sizeof(type)) +#define isl_calloc_type(ctx,type) isl_calloc(ctx,type,sizeof(type)) #define isl_realloc_type(ctx,ptr,type) isl_realloc(ctx,ptr,type,sizeof(type)) #define isl_alloc_array(ctx,type,n) isl_alloc(ctx,type,(n)*sizeof(type)) #define isl_calloc_array(ctx,type,n) (type *)calloc(n, sizeof(type)) -- 2.7.4