зеркало из https://github.com/github/ruby.git
prelude.c.tmpl: get rid of warnings on old gcc
* template/prelude.c.tmpl: ignore missing-field-initializers on old gcc, e.g. 4.4, which does not support pushing/popping diagnostics. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61524 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
Родитель
457521574c
Коммит
d0afbff3b0
|
@ -139,7 +139,7 @@ prelude_prefix_path(VALUE self)
|
|||
|
||||
% unless preludes.empty?
|
||||
#define PRELUDE_STR(n) rb_usascii_str_new_static(prelude_##n.L0, sizeof(prelude_##n))
|
||||
#ifdef __GNUC__
|
||||
#if defined __GNUC__ && __GNUC__ >= 5
|
||||
# pragma GCC diagnostic push
|
||||
# pragma GCC diagnostic error "-Wmissing-field-initializers"
|
||||
#endif
|
||||
|
@ -169,7 +169,7 @@ prelude_eval(VALUE code, VALUE name, int line)
|
|||
NULL, ISEQ_TYPE_TOP, &optimization));
|
||||
rb_ast_dispose(ast);
|
||||
}
|
||||
#ifdef __GNUC__
|
||||
#if defined __GNUC__ && __GNUC__ >= 5
|
||||
# pragma GCC diagnostic pop
|
||||
#endif
|
||||
% end
|
||||
|
|
Загрузка…
Ссылка в новой задаче