Ruby  2.5.0dev(2017-10-22revision60238)
version.h
Go to the documentation of this file.
1 #define RUBY_VERSION "2.5.0"
2 #define RUBY_RELEASE_DATE RUBY_RELEASE_YEAR_STR"-"RUBY_RELEASE_MONTH_STR"-"RUBY_RELEASE_DAY_STR
3 #define RUBY_PATCHLEVEL -1
4 
5 #define RUBY_RELEASE_YEAR 2017
6 #define RUBY_RELEASE_MONTH 10
7 #define RUBY_RELEASE_DAY 22
8 
9 #include "ruby/version.h"
10 
11 #ifndef TOKEN_PASTE
12 #define TOKEN_PASTE(x,y) x##y
13 #endif
14 #define ONLY_ONE_DIGIT(x) TOKEN_PASTE(10,x) < 1000
15 #define WITH_ZERO_PADDING(x) TOKEN_PASTE(0,x)
16 #define RUBY_BIRTH_YEAR_STR STRINGIZE(RUBY_BIRTH_YEAR)
17 #define RUBY_RELEASE_YEAR_STR STRINGIZE(RUBY_RELEASE_YEAR)
18 #if ONLY_ONE_DIGIT(RUBY_RELEASE_MONTH)
19 #define RUBY_RELEASE_MONTH_STR STRINGIZE(WITH_ZERO_PADDING(RUBY_RELEASE_MONTH))
20 #else
21 #define RUBY_RELEASE_MONTH_STR STRINGIZE(RUBY_RELEASE_MONTH)
22 #endif
23 #if ONLY_ONE_DIGIT(RUBY_RELEASE_DAY)
24 #define RUBY_RELEASE_DAY_STR STRINGIZE(WITH_ZERO_PADDING(RUBY_RELEASE_DAY))
25 #else
26 #define RUBY_RELEASE_DAY_STR STRINGIZE(RUBY_RELEASE_DAY)
27 #endif
28 
29 #if !defined RUBY_LIB_VERSION && defined RUBY_LIB_VERSION_STYLE
30 # if RUBY_LIB_VERSION_STYLE == 3
31 # define RUBY_LIB_VERSION STRINGIZE(RUBY_API_VERSION_MAJOR)"."STRINGIZE(RUBY_API_VERSION_MINOR)"."STRINGIZE(RUBY_API_VERSION_TEENY)
32 # elif RUBY_LIB_VERSION_STYLE == 2
33 # define RUBY_LIB_VERSION STRINGIZE(RUBY_API_VERSION_MAJOR)"."STRINGIZE(RUBY_API_VERSION_MINOR)
34 # endif
35 #endif
36 
37 #if RUBY_PATCHLEVEL == -1
38 #define RUBY_PATCHLEVEL_STR "dev"
39 #else
40 #define RUBY_PATCHLEVEL_STR "p"STRINGIZE(RUBY_PATCHLEVEL)
41 #endif
42 
43 #ifndef RUBY_REVISION
44 # include "revision.h"
45 #endif
46 #ifndef RUBY_REVISION
47 # define RUBY_REVISION 0
48 #endif
49 
50 #if RUBY_REVISION
51 # if RUBY_PATCHLEVEL == -1
52 # ifndef RUBY_BRANCH_NAME
53 # define RUBY_BRANCH_NAME "trunk"
54 # endif
55 # define RUBY_REVISION_STR " "RUBY_BRANCH_NAME" "STRINGIZE(RUBY_REVISION)
56 # else
57 # define RUBY_REVISION_STR " revision "STRINGIZE(RUBY_REVISION)
58 # endif
59 #else
60 # define RUBY_REVISION_STR ""
61 #endif
62 
63 # define RUBY_DESCRIPTION \
64  "ruby "RUBY_VERSION \
65  RUBY_PATCHLEVEL_STR \
66  " ("RUBY_RELEASE_DATE \
67  RUBY_REVISION_STR") " \
68  "["RUBY_PLATFORM"]"
69 # define RUBY_COPYRIGHT \
70  "ruby - Copyright (C) " \
71  RUBY_BIRTH_YEAR_STR"-" \
72  RUBY_RELEASE_YEAR_STR" " \
73  RUBY_AUTHOR