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

ruby-changes:38606

From: ko1 <ko1@a...>
Date: Sun, 31 May 2015 03:31:30 +0900 (JST)
Subject: [ruby-changes:38606] ko1:r50687 (trunk): * method.h, vm_method.c (rb_free_method_entry): constify a parameter.

ko1	2015-05-31 03:30:42 +0900 (Sun, 31 May 2015)

  New Revision: 50687

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

  Log:
    * method.h, vm_method.c (rb_free_method_entry): constify a parameter.
    * vm_method.c (rb_unlink_method_entry): constify a parameter.
    * vm_core.h: remove useless declaration about rb_unlink_method_entry().

  Modified files:
    trunk/ChangeLog
    trunk/method.h
    trunk/vm_core.h
    trunk/vm_method.c
Index: method.h
===================================================================
--- method.h	(revision 50686)
+++ method.h	(revision 50687)
@@ -140,7 +140,7 @@ VALUE rb_mod_method_location(VALUE mod, https://github.com/ruby/ruby/blob/trunk/method.h#L140
 VALUE rb_obj_method_location(VALUE obj, ID id);
 
 void rb_mark_method_entry(const rb_method_entry_t *me);
-void rb_free_method_entry(rb_method_entry_t *me);
+void rb_free_method_entry(const rb_method_entry_t *me);
 void rb_sweep_method_entry(void *vm);
 
 #endif /* METHOD_H */
Index: ChangeLog
===================================================================
--- ChangeLog	(revision 50686)
+++ ChangeLog	(revision 50687)
@@ -1,3 +1,11 @@ https://github.com/ruby/ruby/blob/trunk/ChangeLog#L1
+Sun May 31 03:26:58 2015  Koichi Sasada  <ko1@a...>
+
+	* method.h, vm_method.c (rb_free_method_entry): constify a parameter.
+
+	* vm_method.c (rb_unlink_method_entry): constify a parameter.
+
+	* vm_core.h: remove useless declaration about rb_unlink_method_entry().
+
 Sat May 30 18:05:02 2015  NAKAMURA Usaku  <usa@r...>
 
 	* lib/tempfile.rb (Remover#call): fixed wrong condition.  introduced at
Index: vm_core.h
===================================================================
--- vm_core.h	(revision 50686)
+++ vm_core.h	(revision 50687)
@@ -953,7 +953,6 @@ void rb_vm_gvl_destroy(rb_vm_t *vm); https://github.com/ruby/ruby/blob/trunk/vm_core.h#L953
 VALUE rb_vm_call(rb_thread_t *th, VALUE recv, VALUE id, int argc,
 		 const VALUE *argv, const rb_method_entry_t *me,
 		 VALUE defined_class);
-void rb_unlink_method_entry(rb_method_entry_t *me);
 void rb_gc_mark_unlinked_live_method_entries(void *pvm);
 
 void rb_thread_start_timer_thread(void);
Index: vm_method.c
===================================================================
--- vm_method.c	(revision 50686)
+++ vm_method.c	(revision 50687)
@@ -193,10 +193,10 @@ release_method_definition(rb_method_defi https://github.com/ruby/ruby/blob/trunk/vm_method.c#L193
 }
 
 void
-rb_free_method_entry(rb_method_entry_t *me)
+rb_free_method_entry(const rb_method_entry_t *me)
 {
     release_method_definition(me->def);
-    xfree(me);
+    xfree((void *)me);
 }
 
 static inline rb_method_entry_t *search_method(VALUE klass, ID id, VALUE *defined_class_ptr);

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

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