diff options
author | Julian Taylor <jtaylor.debian@googlemail.com> | 2014-09-29 23:03:18 +0200 |
---|---|---|
committer | Julian Taylor <jtaylor.debian@googlemail.com> | 2014-09-29 23:06:44 +0200 |
commit | 5478aafee86af3447b230ede93738cca876844b1 (patch) | |
tree | 777c40d60b16f1d5e0fcd36d37c5c890475bde59 /numpy/core/setup.py | |
parent | 8521e280e7e5e71b89641d06669b82e210cf0b7d (diff) | |
download | numpy-5478aafee86af3447b230ede93738cca876844b1.tar.gz |
BLD: add check for C99 restrict keyword
Define it as NPY_RESTRICT
Restrict indicates a memory block does not alias, gcc supports it in c89
with the __restrict__ keyword.
Diffstat (limited to 'numpy/core/setup.py')
-rw-r--r-- | numpy/core/setup.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/numpy/core/setup.py b/numpy/core/setup.py index 3ad912f40..643eb8e31 100644 --- a/numpy/core/setup.py +++ b/numpy/core/setup.py @@ -446,6 +446,11 @@ def configuration(parent_package='',top_path=None): if sys.platform=='win32' or os.name=='nt': win32_checks(moredefs) + # C99 restrict keyword + restrict = config_cmd.check_restrict() + if restrict: + moredefs.append(('NPY_RESTRICT', restrict)) + # Inline check inline = config_cmd.check_inline() |