diff options
author | Guido van Rossum <guido@python.org> | 1995-08-04 04:20:48 (GMT) |
---|---|---|
committer | Guido van Rossum <guido@python.org> | 1995-08-04 04:20:48 (GMT) |
commit | 667d704997f26a1a22f4e981bbb3c2f8399cfc41 (patch) | |
tree | 245b91f0451e57625f921f02f6f0d3dfb85d59a0 /Python/getversion.c | |
parent | 37ba0bc50be14b6f2148ebb7f824c8e77f001488 (diff) | |
download | cpython-667d704997f26a1a22f4e981bbb3c2f8399cfc41.zip cpython-667d704997f26a1a22f4e981bbb3c2f8399cfc41.tar.gz cpython-667d704997f26a1a22f4e981bbb3c2f8399cfc41.tar.bz2 |
Initial revision
Diffstat (limited to 'Python/getversion.c')
-rw-r--r-- | Python/getversion.c | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/Python/getversion.c b/Python/getversion.c new file mode 100644 index 0000000..1f2accc --- /dev/null +++ b/Python/getversion.c @@ -0,0 +1,21 @@ +/* Return the full version string. */ + +#include "patchlevel.h" + +#define VERSION "%s (%s) %s" + +#ifdef __DATE__ +#define DATE __DATE__ +#else +#define DATE "August 1 1995" +#endif + +extern const char *getcompiler(); + +const char * +getversion() +{ + static char version[80]; + sprintf(version, VERSION, PATCHLEVEL, DATE, getcompiler()); + return version; +} |