[前][次][番号順一覧][スレッド一覧]

ruby-changes:13278

From: nobu <ko1@a...>
Date: Tue, 22 Sep 2009 22:11:29 +0900 (JST)
Subject: [ruby-changes:13278] Ruby:r25040 (trunk): * variable.c: fixed type.

nobu	2009-09-22 22:11:21 +0900 (Tue, 22 Sep 2009)

  New Revision: 25040

  http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=25040

  Log:
    * variable.c: fixed type.

  Modified files:
    trunk/variable.c

Index: variable.c
===================================================================
--- variable.c	(revision 25039)
+++ variable.c	(revision 25040)
@@ -1023,13 +1023,13 @@
 VALUE
 rb_ivar_get(VALUE obj, ID id)
 {
-    return ivar_get(obj, id, Qtrue);
+    return ivar_get(obj, id, TRUE);
 }
 
 VALUE
 rb_attr_get(VALUE obj, ID id)
 {
-    return ivar_get(obj, id, Qfalse);
+    return ivar_get(obj, id, FALSE);
 }
 
 VALUE
@@ -1565,19 +1565,19 @@
 VALUE
 rb_const_get_from(VALUE klass, ID id)
 {
-    return rb_const_get_0(klass, id, Qtrue, Qtrue);
+    return rb_const_get_0(klass, id, TRUE, TRUE);
 }
 
 VALUE
 rb_const_get(VALUE klass, ID id)
 {
-    return rb_const_get_0(klass, id, Qfalse, Qtrue);
+    return rb_const_get_0(klass, id, FALSE, TRUE);
 }
 
 VALUE
 rb_const_get_at(VALUE klass, ID id)
 {
-    return rb_const_get_0(klass, id, Qtrue, Qfalse);
+    return rb_const_get_0(klass, id, TRUE, FALSE);
 }
 
 /*
@@ -1728,8 +1728,8 @@
     while (tmp) {
 	if (RCLASS_IV_TBL(tmp) && st_lookup(RCLASS_IV_TBL(tmp), (st_data_t)id, &value)) {
 	    if ((VALUE)value == Qundef && !autoload_node((VALUE)klass, id, 0))
-		return Qfalse;
-	    return Qtrue;
+		return (int)Qfalse;
+	    return (int)Qtrue;
 	}
 	if (!recurse && klass != rb_cObject) break;
 	tmp = RCLASS_SUPER(tmp);
@@ -1739,25 +1739,25 @@
 	tmp = rb_cObject;
 	goto retry;
     }
-    return Qfalse;
+    return (int)Qfalse;
 }
 
 int
 rb_const_defined_from(VALUE klass, ID id)
 {
-    return rb_const_defined_0(klass, id, Qtrue, Qtrue);
+    return rb_const_defined_0(klass, id, TRUE, TRUE);
 }
 
 int
 rb_const_defined(VALUE klass, ID id)
 {
-    return rb_const_defined_0(klass, id, Qfalse, Qtrue);
+    return rb_const_defined_0(klass, id, FALSE, TRUE);
 }
 
 int
 rb_const_defined_at(VALUE klass, ID id)
 {
-    return rb_const_defined_0(klass, id, Qtrue, Qfalse);
+    return rb_const_defined_0(klass, id, TRUE, FALSE);
 }
 
 static void
@@ -1802,7 +1802,7 @@
 	rb_raise(rb_eTypeError, "no class/module to define constant %s",
 		 rb_id2name(id));
     }
-    mod_av_set(klass, id, val, Qtrue);
+    mod_av_set(klass, id, val, TRUE);
 }
 
 void
@@ -1884,7 +1884,7 @@
     else {
 	target = tmp;
     }
-    mod_av_set(target, id, val, Qfalse);
+    mod_av_set(target, id, val, FALSE);
 }
 
 VALUE

--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]