summaryrefslogtreecommitdiff
path: root/ruby.h
diff options
context:
space:
mode:
authormatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2006-09-07 16:36:40 +0000
committermatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2006-09-07 16:36:40 +0000
commit149a3725cc0adbcf590ce93f8f7013a64eb98f7f (patch)
tree6be4dc56cc3429dcb55919095c32f728a2d441f4 /ruby.h
parent69cd0dfdf9c0d15de2ce48b1856fec3b96ad47b5 (diff)
* ruby.h (RSTRING_PTR): add migration macro.
* ruby.h (RARRAY_PTR): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@10882 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ruby.h')
-rw-r--r--ruby.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/ruby.h b/ruby.h
index 0a75902..68e2ce5 100644
--- a/ruby.h
+++ b/ruby.h
@@ -344,6 +344,8 @@ struct RString {
VALUE shared;
} aux;
};
+#define RSTRING_PTR(s) (RSTRING(s)->ptr)
+#define RSTRING_LEN(s) (RSTRING(s)->len)
struct RArray {
struct RBasic basic;
@@ -354,6 +356,8 @@ struct RArray {
} aux;
VALUE *ptr;
};
+#define RARRAY_PTR(s) (RARRAY(s)->ptr)
+#define RARRAY_LEN(s) (RARRAY(s)->len)
struct RRegexp {
struct RBasic basic;