summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2013-01-08 17:13:26 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2013-01-08 17:13:26 +0000
commit8ad71433279fe8caa1e06038674c0559edfa1468 (patch)
tree80cb3afd208e0a2c5238df38bd76aaaa0bdc2c4f
parenta00b29a67f669c53f7940fa7814a209f7ea47f7e (diff)
ruby.h: align
* include/ruby/ruby.h (RBasic): to be aligned on a VALUE size boundary. [Bug #7647] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@38741 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r--ChangeLog5
-rw-r--r--include/ruby/ruby.h6
2 files changed, 10 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog
index 1f726bd..15be43c 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+Wed Jan 9 02:13:22 2013 Nobuyoshi Nakada <nobu@ruby-lang.org>
+
+ * include/ruby/ruby.h (RBasic): to be aligned on a VALUE size
+ boundary. [Bug #7647]
+
Tue Jan 8 14:41:41 2013 Nobuyoshi Nakada <nobu@ruby-lang.org>
* vm_core.h (rb_iseq_t): move flip_cnt from struct iseq_compile_data,
diff --git a/include/ruby/ruby.h b/include/ruby/ruby.h
index d80eaed..6debe42 100644
--- a/include/ruby/ruby.h
+++ b/include/ruby/ruby.h
@@ -699,7 +699,11 @@ VALUE rb_newobj_of(VALUE, VALUE);
struct RBasic {
VALUE flags;
VALUE klass;
-};
+}
+#ifdef __GNUC__
+ __attribute__((aligned(sizeof(VALUE))))
+#endif
+;
#define ROBJECT_EMBED_LEN_MAX 3
struct RObject {