summaryrefslogtreecommitdiff
path: root/iseq.c
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2016-01-08 10:52:24 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2016-01-08 10:52:24 +0000
commit92f33ef216357e06b122131a3b347e8c63a31156 (patch)
tree334a0236c826db9cdd34865e7e247e136293d3de /iseq.c
parent3ccafdb02764af61d399b51ff0ec42f9b685078d (diff)
iseq.c: volatile only on gcc4.8
* iseq.c (rb_iseq_compile_with_option): no volatile on gcc other than 4.8. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@53465 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'iseq.c')
-rw-r--r--iseq.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/iseq.c b/iseq.c
index 02c3cf1..f72478a 100644
--- a/iseq.c
+++ b/iseq.c
@@ -606,10 +606,10 @@ rb_iseq_compile_with_option(VALUE src, VALUE file, VALUE absolute_path, VALUE li
const rb_iseq_t *const parent = base_block ? base_block->iseq : NULL;
rb_compile_option_t option;
const enum iseq_type type = parent ? ISEQ_TYPE_EVAL : ISEQ_TYPE_TOP;
-#if defined(__GNUC__) && __GNUC__ == 4 && __GNUC_MINOR__ == 8
+#if !defined(__GNUC__) || (__GNUC__ == 4 && __GNUC_MINOR__ == 8)
# define INITIALIZED volatile /* suppress warnings by gcc 4.8 */
#else
-# define INITIALIZED volatile
+# define INITIALIZED /* volatile */
#endif
/* safe results first */
const INITIALIZED int ln = (make_compile_option(&option, opt), NUM2INT(line));