[Python-Dev] C99 (original) (raw)
Guido van Rossum guido at python.org
Sat Jun 4 13:47:38 EDT 2016
- Previous message (by thread): [Python-Dev] C99
- Next message (by thread): [Python-Dev] C99
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Funny. Just two weeks ago I was helping someone who discovered a compiler that doesn't support the new relaxed variable declaration rules. I think it was on Windows. Maybe this move is a little too aggressively deprecating older Windows compilers?
On Sat, Jun 4, 2016 at 10:27 AM, Christian Heimes <christian at python.org> wrote:
On 2016-06-03 23:11, Benjamin Peterson wrote:
PEP 7 requires CPython to use C code conforming to the venerable C89 standard. Traditionally, we've been stuck with C89 due to poor C support in MSVC. However, MSVC 2013 and 2015 implement the key features of C99. C99 does not offer anything earth-shattering; here are the features I think we'd find most interesting: - Variable declarations can be on any line: removes possibly the most annoying limitation of C89. - Inline functions: We can make PyDECREF and PyINCREF inline functions rather than unpleasant macros. - C++-style line comments: Not an killer feature but commonly used. - Booleans In summary, some niceties that would make CPython hacking a little more fun.
So, what say you to updating PEP 7 to allow C99 features for Python 3.6 (in so much as GCC and MSVC support them)? +1 - We never officially deprecated C89 platforms withou 64 bit integers in PEP 7. Victor's changes to pytime.h implies support for uint64t and int64t. C99 has mandatory long long int support. - If we also drop Solaris Studio C compiler support, we can replace header guards (e.g. #ifndef PyPYTHONH) with #pragma once Christian
Python-Dev mailing list Python-Dev at python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/guido%40python.org
-- --Guido van Rossum (python.org/~guido)
- Previous message (by thread): [Python-Dev] C99
- Next message (by thread): [Python-Dev] C99
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]