Skip to content
Commit f75c3b74 authored by Francis Herne's avatar Francis Herne
Browse files

Restore compile-time support for Python 3.4.3+

Since 6d0b7646 (~5.0-beta1) the minimum Python version has been 3.5.0,
 but OpenSUSE Leap want to use KDevelop 5 and still have Python 3.4.

There are major breaking changes between 3.4.2 and 3.4.3, so earlier
 versions will not be supported.

Now supported are 3.4.3+, 3.5.x and 3.6.x.

Syntax from Python versions newer than the one kdev-python is compiled
 against will not be recognised and will cause false-positive errors
 to be displayed to users. Please use the most recent version unless
 there are unavoidable reasons to use an older one.

---------

In function calls:
 - 'stararg' is replaced by a StarredAst at the end of 'arguments'.
 - 'kwargs' is replaced by a KeywordAst at the end of 'keywords'.

A new CODE block in python36.sdef converts 3.4-style AST to the newer
 format used by Python 3.5+ and within kdev-python. The conversion
 script is tweaked to allow both CODE and SINCE on the same line, and
 a new BEFORE directive (inverse of SINCE).

Operator @ (__matmul__) is inserted into the middle of the enum, so all
 operators listed later have a different index.

All other AST changes are just new additions.

No new tests. No test changes with Python 3.5+.
All tests pass with 3.4 except those using newer syntax.

Differential Revision: https://phabricator.kde.org/D4936
parent c342c91c
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment