Guido van Rossum | f1176c4 | 1999-01-03 12:40:24 +0000 | [diff] [blame] | 1 | |
Guido van Rossum | 45aecf4 | 2006-03-15 04:58:47 +0000 | [diff] [blame] | 2 | /* Python version identification scheme. |
Guido van Rossum | f1176c4 | 1999-01-03 12:40:24 +0000 | [diff] [blame] | 3 | |
| 4 | When the major or minor version changes, the VERSION variable in |
| 5 | configure.in must also be changed. |
| 6 | |
| 7 | There is also (independent) API version information in modsupport.h. |
| 8 | */ |
| 9 | |
| 10 | /* Values for PY_RELEASE_LEVEL */ |
| 11 | #define PY_RELEASE_LEVEL_ALPHA 0xA |
| 12 | #define PY_RELEASE_LEVEL_BETA 0xB |
Anthony Baxter | 49d4213 | 2004-11-15 15:03:25 +0000 | [diff] [blame] | 13 | #define PY_RELEASE_LEVEL_GAMMA 0xC /* For release candidates */ |
Guido van Rossum | f1176c4 | 1999-01-03 12:40:24 +0000 | [diff] [blame] | 14 | #define PY_RELEASE_LEVEL_FINAL 0xF /* Serial should be 0 here */ |
Guido van Rossum | 9e47859 | 1999-04-13 14:47:26 +0000 | [diff] [blame] | 15 | /* Higher for patch releases */ |
Guido van Rossum | f1176c4 | 1999-01-03 12:40:24 +0000 | [diff] [blame] | 16 | |
| 17 | /* Version parsed out into numeric values */ |
Barry Warsaw | bb5cd08 | 2008-04-02 23:33:27 +0000 | [diff] [blame] | 18 | /*--start constants--*/ |
Neal Norwitz | ade612b | 2006-03-17 08:27:50 +0000 | [diff] [blame] | 19 | #define PY_MAJOR_VERSION 3 |
Georg Brandl | 3ebb6b3 | 2011-02-20 10:37:07 +0000 | [diff] [blame] | 20 | #define PY_MINOR_VERSION 3 |
Guido van Rossum | 21a50bd | 2000-03-29 01:46:45 +0000 | [diff] [blame] | 21 | #define PY_MICRO_VERSION 0 |
Georg Brandl | 3ebb6b3 | 2011-02-20 10:37:07 +0000 | [diff] [blame] | 22 | #define PY_RELEASE_LEVEL PY_RELEASE_LEVEL_ALPHA |
Georg Brandl | 260a788 | 2011-02-20 10:29:04 +0000 | [diff] [blame] | 23 | #define PY_RELEASE_SERIAL 0 |
Guido van Rossum | f1176c4 | 1999-01-03 12:40:24 +0000 | [diff] [blame] | 24 | |
| 25 | /* Version as a string */ |
Georg Brandl | 3ebb6b3 | 2011-02-20 10:37:07 +0000 | [diff] [blame] | 26 | #define PY_VERSION "3.3a0" |
Barry Warsaw | bb5cd08 | 2008-04-02 23:33:27 +0000 | [diff] [blame] | 27 | /*--end constants--*/ |
Guido van Rossum | f1176c4 | 1999-01-03 12:40:24 +0000 | [diff] [blame] | 28 | |
| 29 | /* Version as a single 4-byte hex number, e.g. 0x010502B2 == 1.5.2b2. |
| 30 | Use this for numeric comparisons, e.g. #if PY_VERSION_HEX >= ... */ |
| 31 | #define PY_VERSION_HEX ((PY_MAJOR_VERSION << 24) | \ |
| 32 | (PY_MINOR_VERSION << 16) | \ |
| 33 | (PY_MICRO_VERSION << 8) | \ |
| 34 | (PY_RELEASE_LEVEL << 4) | \ |
| 35 | (PY_RELEASE_SERIAL << 0)) |