зеркало из https://github.com/github/ruby.git
use stringized macros
* version.h (RUBY_COPYRIGHT): use stringized macros, RUBY_BIRTH_YEAR_STR and RUBY_RELEASE_YEAR_STR. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@53478 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
Родитель
d43ef66b12
Коммит
612edc7706
|
@ -13,6 +13,7 @@
|
|||
#endif
|
||||
#define ONLY_ONE_DIGIT(x) TOKEN_PASTE(10,x) < 1000
|
||||
#define WITH_ZERO_PADDING(x) TOKEN_PASTE(0,x)
|
||||
#define RUBY_BIRTH_YEAR_STR STRINGIZE(RUBY_BIRTH_YEAR)
|
||||
#define RUBY_RELEASE_YEAR_STR STRINGIZE(RUBY_RELEASE_YEAR)
|
||||
#if ONLY_ONE_DIGIT(RUBY_RELEASE_MONTH)
|
||||
#define RUBY_RELEASE_MONTH_STR STRINGIZE(WITH_ZERO_PADDING(RUBY_RELEASE_MONTH))
|
||||
|
@ -67,6 +68,6 @@
|
|||
"["RUBY_PLATFORM"]"
|
||||
# define RUBY_COPYRIGHT \
|
||||
"ruby - Copyright (C) " \
|
||||
STRINGIZE(RUBY_BIRTH_YEAR)"-" \
|
||||
STRINGIZE(RUBY_RELEASE_YEAR)" " \
|
||||
RUBY_BIRTH_YEAR_STR"-" \
|
||||
RUBY_RELEASE_YEAR_STR" " \
|
||||
RUBY_AUTHOR
|
||||
|
|
Загрузка…
Ссылка в новой задаче