[Libclc-dev] [PATCH] clctypes.h: Don't rely on stddef.h for size_t and ptrdiff_t

Jeroen Ketema j.ketema at imperial.ac.uk
Wed Mar 19 07:52:40 PDT 2014


I believe we loose access to NULL in this way, or not?

Although NULL is not officially in the standard, it might be useful to have it around?

Jeroen

On 19 Mar 2014, at 14:49, Aaron Watry <awatry at gmail.com> wrote:

> Fixes the build and run-time for me with llvm 3.5.0 git/svn
> 
> Tested-by: Aaron Watry <awatry at gmail.com>
> 
> On Tue, Mar 18, 2014 at 5:50 PM, Tom Stellard <thomas.stellard at amd.com> wrote:
>> ---
>> generic/include/clc/clctypes.h | 3 ++-
>> 1 file changed, 2 insertions(+), 1 deletion(-)
>> 
>> diff --git a/generic/include/clc/clctypes.h b/generic/include/clc/clctypes.h
>> index ca729f7..30c45f6 100644
>> --- a/generic/include/clc/clctypes.h
>> +++ b/generic/include/clc/clctypes.h
>> @@ -1,6 +1,7 @@
>> /* 6.1.1 Built-in Scalar Data Types */
>> 
>> -#include <stddef.h>
>> +typedef __SIZE_TYPE__ size_t;
>> +typedef __PTRDIFF_TYPE__ ptrdiff_t;
>> 
>> typedef unsigned char uchar;
>> typedef unsigned short ushort;
>> --
>> 1.8.1.4
>> 
>> 
>> 
>> _______________________________________________
>> Libclc-dev mailing list
>> Libclc-dev at pcc.me.uk
>> http://www.pcc.me.uk/cgi-bin/mailman/listinfo/libclc-dev
> 
> _______________________________________________
> Libclc-dev mailing list
> Libclc-dev at pcc.me.uk
> http://www.pcc.me.uk/cgi-bin/mailman/listinfo/libclc-dev





More information about the Libclc-dev mailing list