Skip to content

Commit fa507b3

Browse files
authored
Merge pull request #460 from notoraptor/fix-win-compil-py2
(small fix) add global inline definition for MSVC 2008
2 parents e15d70b + 05110ad commit fa507b3

File tree

5 files changed

+3
-19
lines changed

5 files changed

+3
-19
lines changed

src/gpuarray/array.h

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -8,12 +8,6 @@
88
#include <gpuarray/buffer.h>
99
#include <gpuarray/util.h>
1010

11-
#ifdef _MSC_VER
12-
#ifndef inline
13-
#define inline __inline
14-
#endif
15-
#endif
16-
1711
#ifdef __cplusplus
1812
extern "C" {
1913
#endif

src/gpuarray/config.h

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,9 @@
2525

2626
#ifdef _MSC_VER
2727
#include <stddef.h>
28+
#ifndef inline
29+
#define inline __inline
30+
#endif
2831
#if _MSC_VER < 1600
2932
#include <gpuarray/wincompat/stdint.h>
3033
#else

src/gpuarray_buffer_opencl.c

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -15,10 +15,6 @@
1515
#include "loaders/libclblas.h"
1616
#include "loaders/libclblast.h"
1717

18-
#ifdef _MSC_VER
19-
#define strdup _strdup
20-
#endif
21-
2218
#define _unused(x) ((void)x)
2319
#define SSIZE_MIN (-(SSIZE_MAX-1))
2420

src/private_config.h.in

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,6 @@ extern "C" {
2323
/* God damn Microsoft ... */
2424
#define snprintf _snprintf
2525
#define strdup _strdup
26-
/* MS VC++ 2008 does not support inline */
27-
#define inline __inline
2826
#define alloca _alloca
2927
#endif
3028

src/util/error.h

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -6,13 +6,6 @@
66

77
#include <gpuarray/error.h>
88

9-
/* MSVC 2008 does not support "inline". */
10-
#ifdef _MSC_VER
11-
#ifndef inline
12-
#define inline __inline
13-
#endif
14-
#endif
15-
169
/* 1024 - 4 for the int that goes after */
1710
#define ERROR_MSGBUF_LEN 1020
1811

0 commit comments

Comments
 (0)