mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* io.c (rb_io_open), math.c (domain_check), object.c (boot_defclass):
constified. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@23704 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
a4349c6b06
commit
47fc6a3ad0
4 changed files with 17 additions and 4 deletions
|
@ -1,3 +1,8 @@
|
|||
Tue Jun 16 22:23:00 2009 Nobuyoshi Nakada <nobu@ruby-lang.org>
|
||||
|
||||
* io.c (rb_io_open), math.c (domain_check), object.c (boot_defclass):
|
||||
constified.
|
||||
|
||||
Tue Jun 16 09:11:36 2009 Yukihiro Matsumoto <matz@ruby-lang.org>
|
||||
|
||||
* io.c (argf_close): always call #close method. [ruby-core:23853]
|
||||
|
|
8
io.c
8
io.c
|
@ -3092,8 +3092,10 @@ pipe_del_fptr(fptr)
|
|||
}
|
||||
}
|
||||
|
||||
static void pipe_atexit _((void));
|
||||
|
||||
static void
|
||||
pipe_atexit _((void))
|
||||
pipe_atexit()
|
||||
{
|
||||
struct pipe_list *list = pipe_list;
|
||||
struct pipe_list *tmp;
|
||||
|
@ -3606,9 +3608,11 @@ rb_f_open(argc, argv)
|
|||
return rb_io_s_open(argc, argv, rb_cFile);
|
||||
}
|
||||
|
||||
static VALUE rb_io_open _((const char *fname, const char *mode));
|
||||
|
||||
static VALUE
|
||||
rb_io_open(fname, mode)
|
||||
char *fname, *mode;
|
||||
const char *fname, *mode;
|
||||
{
|
||||
if (fname[0] == '|') {
|
||||
return pipe_open(0, fname+1, mode);
|
||||
|
|
4
math.c
4
math.c
|
@ -22,10 +22,12 @@ VALUE rb_mMath;
|
|||
Need_Float(y);\
|
||||
} while (0)
|
||||
|
||||
static void domain_check _((double x, const char *msg));
|
||||
|
||||
static void
|
||||
domain_check(x, msg)
|
||||
double x;
|
||||
char *msg;
|
||||
const char *msg;
|
||||
{
|
||||
while(1) {
|
||||
if (errno) {
|
||||
|
|
4
object.c
4
object.c
|
@ -2614,9 +2614,11 @@ rb_f_array(obj, arg)
|
|||
return rb_Array(arg);
|
||||
}
|
||||
|
||||
static VALUE boot_defclass _((const char *name, VALUE super));
|
||||
|
||||
static VALUE
|
||||
boot_defclass(name, super)
|
||||
char *name;
|
||||
const char *name;
|
||||
VALUE super;
|
||||
{
|
||||
extern st_table *rb_class_tbl;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue