summaryrefslogtreecommitdiff
path: root/ext/tk/tcltklib.c
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2006-09-05 13:07:06 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2006-09-05 13:07:06 +0000
commitca9d8f09301bac7f07546da1a69e213899f1405f (patch)
treeafde08d28d3b624a60ef5091747f25851d20e04e /ext/tk/tcltklib.c
parent6a0636b2d40424faa55cd864db28649d0de1b942 (diff)
* ext/tk/tcltklib.c: use rb_ary_new3() since RARRAY_LEN() is not l-value.
* ext/tk/tkutil/tkutil.c: use RARRAY_PTR() and RARRAY_LEN() and etc. fixed: [ruby-dev:29473] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@10866 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext/tk/tcltklib.c')
-rw-r--r--ext/tk/tcltklib.c12
1 files changed, 3 insertions, 9 deletions
diff --git a/ext/tk/tcltklib.c b/ext/tk/tcltklib.c
index 9086f3e4ab..45f6a82e65 100644
--- a/ext/tk/tcltklib.c
+++ b/ext/tk/tcltklib.c
@@ -5584,9 +5584,7 @@ tk_funcall(func, argc, argv, obj)
Tcl_Preserve(callq);
/* allocate result obj */
- result = rb_ary_new2(1);
- RARRAY_PTR(result)[0] = Qnil;
- RARRAY_LEN(result) = 1;
+ result = rb_ary_new3(1, Qnil);
/* construct event data */
callq->done = alloc_done;
@@ -5899,9 +5897,7 @@ ip_eval(self, str)
Tcl_Preserve(evq);
/* allocate result obj */
- result = rb_ary_new2(1);
- RARRAY_PTR(result)[0] = Qnil;
- RARRAY_LEN(result) = 1;
+ result = rb_ary_new3(1, Qnil);
/* construct event data */
evq->done = alloc_done;
@@ -6979,9 +6975,7 @@ ip_invoke_with_position(argc, argv, obj, position)
Tcl_Preserve(ivq);
/* allocate result obj */
- result = rb_ary_new2(1);
- RARRAY_PTR(result)[0] = Qnil;
- RARRAY_LEN(result) = 1;
+ result = rb_ary_new3(1, Qnil);
/* construct event data */
ivq->done = alloc_done;