summaryrefslogtreecommitdiffhomepage
path: root/src/array.c
diff options
context:
space:
mode:
authorYukihiro Matz Matsumoto <[email protected]>2013-03-27 23:41:23 +0900
committerYukihiro Matz Matsumoto <[email protected]>2013-03-27 23:41:23 +0900
commit18b2683b97ae54d4f2f15c19076f33aa29eaf2b7 (patch)
treef6afd41abfd7b0ad8b76bb5e618e6ee0fbdc6723 /src/array.c
parent8ce842a5d978132c5733cacb7c15bb3d0f5ce66d (diff)
downloadmruby-18b2683b97ae54d4f2f15c19076f33aa29eaf2b7.tar.gz
mruby-18b2683b97ae54d4f2f15c19076f33aa29eaf2b7.zip
use new mrb_format API from mrb_raisef; its only format specifier is "%S" (stringify) and takes mrb_value; close #1062
Diffstat (limited to 'src/array.c')
-rw-r--r--src/array.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/array.c b/src/array.c
index f9cc9119c..a20fa6daf 100644
--- a/src/array.c
+++ b/src/array.c
@@ -578,7 +578,7 @@ mrb_ary_set(mrb_state *mrb, mrb_value ary, mrb_int n, mrb_value val) /* rb_ary_s
if (n < 0) {
n += a->len;
if (n < 0) {
- mrb_raisef(mrb, E_INDEX_ERROR, "index %" PRIdMRB_INT " out of array", n - a->len);
+ mrb_raisef(mrb, E_INDEX_ERROR, "index %S out of array", mrb_fixnum_value(n - a->len));
}
}
if (a->len <= (int)n) {