1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

Use 'P' instead of 'p' in types.rb.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@7371 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
ttate 2004-11-25 08:15:29 +00:00
parent 058c1d1620
commit f7a5ee56d7
3 changed files with 6 additions and 6 deletions

View file

@ -92,7 +92,7 @@ rb_dl_scan_callback_args(long stack[], const char *proto,
}
break;
default:
rb_raise(rb_eDLTypeError, "unsupported type `%c'", proto[i]);
rb_raise(rb_eDLTypeError, "scan_callback_args: unsupported type `%c'", proto[i]);
break;
}
argv[i-1] = val;

View file

@ -153,7 +153,7 @@ module DL
"S",nil, nil],
[/^const char\s*\*$/,"S",nil, nil,
"S",nil, nil],
[/^.+\*$/, "p", nil, nil,
[/^.+\*$/, "P", nil, nil,
"P", nil, nil],
[/^.+\[\]$/, "a", nil, nil,
"a", nil, nil],
@ -186,8 +186,8 @@ module DL
# t1 = Regexp.new("^" + t1 + "$")
# end
if( (t1.is_a?(Regexp) && (t1 =~ ty)) || (t1 == ty) )
ty1 = ty.gsub(t1,t2)
ty2 = ty.gsub(t1,t3)
ty1 = ty.gsub(t1,t2) if t2
ty2 = ty.gsub(t1,t3) if t3
ty1.strip! if ty1
ty2.strip! if ty2
if( enc )

View file

@ -697,7 +697,7 @@ cary2ary(void *ptr, char t, int len)
ptr = (char *)ptr + sizeof(short);
break;
default:
rb_raise(rb_eDLTypeError, "unsupported type '%c'", t);
rb_raise(rb_eDLTypeError, "cary2ary: unsupported type '%c'", t);
}
return elem;
}
@ -735,7 +735,7 @@ cary2ary(void *ptr, char t, int len)
ptr = (char *)ptr + sizeof(short);
break;
default:
rb_raise(rb_eDLTypeError, "unsupported type '%c'", t);
rb_raise(rb_eDLTypeError, "cary2ary: unsupported type '%c'", t);
}
rb_ary_push(ary, elem);
}