summaryrefslogtreecommitdiff
path: root/setup.py
diff options
context:
space:
mode:
authorStefan Behnel <stefan_ml@behnel.de>2018-08-25 10:28:49 +0200
committerStefan Behnel <stefan_ml@behnel.de>2018-09-16 12:31:10 +0200
commitc8e6f375dab5589ea2441775e193d650119dc9b2 (patch)
tree5791a19678fae5b6dc94d543531e18f5cbae9861 /setup.py
parente59d4dcf6c93e8e4c330bca57cbad90476776531 (diff)
downloadcython-c8e6f375dab5589ea2441775e193d650119dc9b2.tar.gz
Warn when no "language_level" is specified to prepare the transition to language_level=3.
Closes #2593.
Diffstat (limited to 'setup.py')
-rwxr-xr-xsetup.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/setup.py b/setup.py
index f44f33e8c..a94fc0d39 100755
--- a/setup.py
+++ b/setup.py
@@ -156,8 +156,9 @@ def compile_cython_modules(profile=False, compile_more=False, cython_with_refnan
extensions[-1].sources[0] = pyx_source_file
from Cython.Distutils.build_ext import new_build_ext
+ from Cython.Compiler.Options import get_directive_defaults
+ get_directive_defaults()['language_level'] = 2
if profile:
- from Cython.Compiler.Options import get_directive_defaults
get_directive_defaults()['profile'] = True
sys.stderr.write("Enabled profiling for the Cython binary modules\n")