summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--ChangeLog8
-rw-r--r--class.c20
-rw-r--r--include/ruby/intern.h1
-rw-r--r--include/ruby/node.h3
-rw-r--r--object.c2
5 files changed, 9 insertions, 25 deletions
diff --git a/ChangeLog b/ChangeLog
index ecf00c5b2..4317e0b3b 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,11 @@
+Thu Oct 11 21:10:17 2007 Yukihiro Matsumoto <matz@ruby-lang.org>
+
+ * include/ruby/node.h (NOEX_LOCAL): remove unused local visibility.
+
+ * class.c (ins_methods_push): ditto.
+
+ * class.c (rb_class_local_methods): method removed.
+
Thu Oct 11 14:29:31 2007 NAKAMURA Usaku <usa@ruby-lang.org>
* */Makefile.sub (COMMON_MACROS): workaround for old SDK's bug.
diff --git a/class.c b/class.c
index ead4d767a..5bb801d2e 100644
--- a/class.c
+++ b/class.c
@@ -521,7 +521,6 @@ ins_methods_push(ID name, long type, VALUE ary, long visi)
case NOEX_PRIVATE:
case NOEX_PROTECTED:
case NOEX_PUBLIC:
- case NOEX_LOCAL:
visi = (type == visi);
break;
default:
@@ -559,12 +558,6 @@ ins_methods_pub_i(ID name, long type, VALUE ary)
}
static int
-ins_methods_local_i(ID name, long type, VALUE ary)
-{
- return ins_methods_push(name, type, ary, NOEX_LOCAL);
-}
-
-static int
method_entry(ID key, NODE *body, st_table *list)
{
long type;
@@ -703,19 +696,6 @@ rb_class_public_instance_methods(int argc, VALUE *argv, VALUE mod)
/*
* call-seq:
- * mod.local_methods => array
- *
- * Returns a list of the local methods defined in <i>mod</i>.
- */
-
-VALUE
-rb_class_local_methods(VALUE mod)
-{
- return class_instance_method_list(0, 0, mod, ins_methods_local_i);
-}
-
-/*
- * call-seq:
* obj.singleton_methods(all=true) => array
*
* Returns an array of the names of singleton methods for <i>obj</i>.
diff --git a/include/ruby/intern.h b/include/ruby/intern.h
index 8c39e2a6b..2b50364d7 100644
--- a/include/ruby/intern.h
+++ b/include/ruby/intern.h
@@ -136,7 +136,6 @@ VALUE rb_class_instance_methods(int, VALUE*, VALUE);
VALUE rb_class_public_instance_methods(int, VALUE*, VALUE);
VALUE rb_class_protected_instance_methods(int, VALUE*, VALUE);
VALUE rb_class_private_instance_methods(int, VALUE*, VALUE);
-VALUE rb_class_local_methods(VALUE);
VALUE rb_obj_singleton_methods(int, VALUE*, VALUE);
void rb_define_method_id(VALUE, ID, VALUE (*)(ANYARGS), int);
void rb_frozen_class_p(VALUE);
diff --git a/include/ruby/node.h b/include/ruby/node.h
index a5b66d35f..51268061e 100644
--- a/include/ruby/node.h
+++ b/include/ruby/node.h
@@ -467,8 +467,7 @@ typedef struct RNode {
#define NOEX_NOSUPER 0x01
#define NOEX_PRIVATE 0x02
#define NOEX_PROTECTED 0x04
-#define NOEX_LOCAL 0x08
-#define NOEX_MASK 0x0E /* 1110 */
+#define NOEX_MASK 0x06 /* 1110 */
#define NOEX_UNDEF NOEX_NOSUPER
diff --git a/object.c b/object.c
index 031d2afdc..660c9e1fe 100644
--- a/object.c
+++ b/object.c
@@ -2436,8 +2436,6 @@ Init_Object(void)
rb_class_protected_instance_methods, -1); /* in class.c */
rb_define_method(rb_cModule, "private_instance_methods",
rb_class_private_instance_methods, -1); /* in class.c */
- rb_define_method(rb_cModule, "local_methods",
- rb_class_local_methods, 0); /* in class.c */
rb_define_method(rb_cModule, "constants", rb_mod_constants, -1); /* in variable.c */
rb_define_method(rb_cModule, "const_get", rb_mod_const_get, -1);