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

ruby-changes:35711

From: nobu <ko1@a...>
Date: Sun, 5 Oct 2014 08:29:37 +0900 (JST)
Subject: [ruby-changes:35711] nobu:r47793 (trunk): ext: protoize no-arguments functions

nobu	2014-10-05 08:29:24 +0900 (Sun, 05 Oct 2014)

  New Revision: 47793

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

  Log:
    ext: protoize no-arguments functions

  Modified files:
    trunk/ext/fiddle/closure.h
    trunk/ext/fiddle/function.h
    trunk/ext/json/generator/generator.h
    trunk/ext/json/parser/parser.h
    trunk/ext/psych/psych_emitter.h
    trunk/ext/psych/psych_parser.h
    trunk/ext/tk/stubs.h
    trunk/ext/tk/tcltklib.c
    trunk/ext/win32ole/win32ole.h
    trunk/ext/win32ole/win32ole_error.c
    trunk/ext/win32ole/win32ole_error.h
    trunk/ext/win32ole/win32ole_event.c
    trunk/ext/win32ole/win32ole_event.h
    trunk/ext/win32ole/win32ole_method.h
    trunk/ext/win32ole/win32ole_param.h
    trunk/ext/win32ole/win32ole_record.h
    trunk/ext/win32ole/win32ole_type.h
    trunk/ext/win32ole/win32ole_typelib.h
    trunk/ext/win32ole/win32ole_variable.h
    trunk/ext/win32ole/win32ole_variant.h
    trunk/ext/win32ole/win32ole_variant_m.c
    trunk/ext/win32ole/win32ole_variant_m.h
Index: ext/win32ole/win32ole_typelib.h
===================================================================
--- ext/win32ole/win32ole_typelib.h	(revision 47792)
+++ ext/win32ole/win32ole_typelib.h	(revision 47793)
@@ -3,7 +3,7 @@ https://github.com/ruby/ruby/blob/trunk/ext/win32ole/win32ole_typelib.h#L3
 
 VALUE cWIN32OLE_TYPELIB;
 
-void Init_win32ole_typelib();
+void Init_win32ole_typelib(void);
 ITypeLib * itypelib(VALUE self);
 VALUE typelib_file(VALUE ole);
 VALUE create_win32ole_typelib(ITypeLib *pTypeLib);
Index: ext/win32ole/win32ole_variant_m.c
===================================================================
--- ext/win32ole/win32ole_variant_m.c	(revision 47792)
+++ ext/win32ole/win32ole_variant_m.c	(revision 47793)
@@ -1,6 +1,7 @@ https://github.com/ruby/ruby/blob/trunk/ext/win32ole/win32ole_variant_m.c#L1
 #include "win32ole.h"
 
-void Init_win32ole_variant_m() {
+void Init_win32ole_variant_m(void)
+{
     /*
      * Document-module: WIN32OLE::VARIANT
      *
Index: ext/win32ole/win32ole_event.c
===================================================================
--- ext/win32ole/win32ole_event.c	(revision 47792)
+++ ext/win32ole/win32ole_event.c	(revision 47793)
@@ -283,7 +283,8 @@ STDMETHODIMP EVENTSINK_GetIDsOfNames( https://github.com/ruby/ruby/blob/trunk/ext/win32ole/win32ole_event.c#L283
 }
 
 PIEVENTSINKOBJ
-EVENTSINK_Constructor() {
+EVENTSINK_Constructor(void)
+{
     PIEVENTSINKOBJ pEv;
     if (!g_IsEventSinkVtblInitialized) {
         vtEventSink.QueryInterface=EVENTSINK_QueryInterface;
@@ -976,7 +977,8 @@ fev_initialize(int argc, VALUE *argv, VA https://github.com/ruby/ruby/blob/trunk/ext/win32ole/win32ole_event.c#L977
 }
 
 static void
-ole_msg_loop() {
+ole_msg_loop(void)
+{
     MSG msg;
     while(PeekMessage(&msg,NULL,0,0,PM_REMOVE)) {
         TranslateMessage(&msg);
Index: ext/win32ole/win32ole_record.h
===================================================================
--- ext/win32ole/win32ole_record.h	(revision 47792)
+++ ext/win32ole/win32ole_record.h	(revision 47793)
@@ -5,6 +5,6 @@ VALUE cWIN32OLE_RECORD; https://github.com/ruby/ruby/blob/trunk/ext/win32ole/win32ole_record.h#L5
 void ole_rec2variant(VALUE rec, VARIANT *var);
 void olerecord_set_ivar(VALUE obj, IRecordInfo *pri, void *prec);
 VALUE create_win32ole_record(IRecordInfo *pri, void *prec);
-void Init_win32ole_record();
+void Init_win32ole_record(void);
 
 #endif
Index: ext/win32ole/win32ole_variant_m.h
===================================================================
--- ext/win32ole/win32ole_variant_m.h	(revision 47792)
+++ ext/win32ole/win32ole_variant_m.h	(revision 47793)
@@ -2,6 +2,6 @@ https://github.com/ruby/ruby/blob/trunk/ext/win32ole/win32ole_variant_m.h#L2
 #define WIN32OLE_VARIANT_M_H 1
 
 VALUE mWIN32OLE_VARIANT;
-void Init_win32ole_variant_m();
+void Init_win32ole_variant_m(void);
 
 #endif
Index: ext/win32ole/win32ole.h
===================================================================
--- ext/win32ole/win32ole.h	(revision 47792)
+++ ext/win32ole/win32ole.h	(revision 47793)
@@ -135,7 +135,7 @@ VALUE ole_wc2vstr(LPWSTR pw, BOOL isfree https://github.com/ruby/ruby/blob/trunk/ext/win32ole/win32ole.h#L135
 
 #define WC2VSTR(x) ole_wc2vstr((x), TRUE)
 
-BOOL ole_initialized();
+BOOL ole_initialized(void);
 HRESULT ole_docinfo_from_type(ITypeInfo *pTypeInfo, BSTR *name, BSTR *helpstr, DWORD *helpcontext, BSTR *helpfile);
 VALUE ole_typedesc2val(ITypeInfo *pTypeInfo, TYPEDESC *pTypeDesc, VALUE typedetails);
 VALUE make_inspect(const char *class_name, VALUE detail);
Index: ext/win32ole/win32ole_method.h
===================================================================
--- ext/win32ole/win32ole_method.h	(revision 47792)
+++ ext/win32ole/win32ole_method.h	(revision 47793)
@@ -11,5 +11,5 @@ VALUE cWIN32OLE_METHOD; https://github.com/ruby/ruby/blob/trunk/ext/win32ole/win32ole_method.h#L11
 VALUE folemethod_s_allocate(VALUE klass);
 VALUE ole_methods_from_typeinfo(ITypeInfo *pTypeInfo, int mask);
 VALUE create_win32ole_method(ITypeInfo *pTypeInfo, VALUE name);
-void Init_win32ole_method();
+void Init_win32ole_method(void);
 #endif
Index: ext/win32ole/win32ole_type.h
===================================================================
--- ext/win32ole/win32ole_type.h	(revision 47792)
+++ ext/win32ole/win32ole_type.h	(revision 47793)
@@ -4,5 +4,5 @@ VALUE cWIN32OLE_TYPE; https://github.com/ruby/ruby/blob/trunk/ext/win32ole/win32ole_type.h#L4
 VALUE create_win32ole_type(ITypeInfo *pTypeInfo, VALUE name);
 ITypeInfo *itypeinfo(VALUE self);
 VALUE ole_type_from_itypeinfo(ITypeInfo *pTypeInfo);
-void Init_win32ole_type();
+void Init_win32ole_type(void);
 #endif
Index: ext/win32ole/win32ole_event.h
===================================================================
--- ext/win32ole/win32ole_event.h	(revision 47792)
+++ ext/win32ole/win32ole_event.h	(revision 47793)
@@ -1,6 +1,6 @@ https://github.com/ruby/ruby/blob/trunk/ext/win32ole/win32ole_event.h#L1
 #ifndef WIN32OLE_EVENT_H
 #define WIN32OLE_EVENT_H 1
 
-void Init_win32ole_event();
+void Init_win32ole_event(void);
 
 #endif
Index: ext/win32ole/win32ole_error.c
===================================================================
--- ext/win32ole/win32ole_error.c	(revision 47792)
+++ ext/win32ole/win32ole_error.c	(revision 47793)
@@ -61,7 +61,8 @@ ole_raise(HRESULT hr, VALUE ecs, const c https://github.com/ruby/ruby/blob/trunk/ext/win32ole/win32ole_error.c#L61
 }
 
 void
-Init_win32ole_error() {
+Init_win32ole_error(void)
+{
     /*
      * Document-class: WIN32OLERuntimeError
      *
Index: ext/win32ole/win32ole_variable.h
===================================================================
--- ext/win32ole/win32ole_variable.h	(revision 47792)
+++ ext/win32ole/win32ole_variable.h	(revision 47793)
@@ -3,6 +3,6 @@ https://github.com/ruby/ruby/blob/trunk/ext/win32ole/win32ole_variable.h#L3
 
 VALUE cWIN32OLE_VARIABLE;
 VALUE create_win32ole_variable(ITypeInfo *pTypeInfo, UINT index, VALUE name);
-void Init_win32ole_variable();
+void Init_win32ole_variable(void);
 
 #endif
Index: ext/win32ole/win32ole_error.h
===================================================================
--- ext/win32ole/win32ole_error.h	(revision 47792)
+++ ext/win32ole/win32ole_error.h	(revision 47793)
@@ -3,6 +3,6 @@ https://github.com/ruby/ruby/blob/trunk/ext/win32ole/win32ole_error.h#L3
 
 VALUE eWIN32OLERuntimeError;
 void ole_raise(HRESULT hr, VALUE ecs, const char *fmt, ...);
-void Init_win32ole_error();
+void Init_win32ole_error(void);
 
 #endif
Index: ext/win32ole/win32ole_param.h
===================================================================
--- ext/win32ole/win32ole_param.h	(revision 47792)
+++ ext/win32ole/win32ole_param.h	(revision 47793)
@@ -2,7 +2,7 @@ https://github.com/ruby/ruby/blob/trunk/ext/win32ole/win32ole_param.h#L2
 #define WIN32OLE_PARAM_H
 
 VALUE create_win32ole_param(ITypeInfo *pTypeInfo, UINT method_index, UINT index, VALUE name);
-void Init_win32ole_param();
+void Init_win32ole_param(void);
 
 #endif
 
Index: ext/win32ole/win32ole_variant.h
===================================================================
--- ext/win32ole/win32ole_variant.h	(revision 47792)
+++ ext/win32ole/win32ole_variant.h	(revision 47793)
@@ -7,7 +7,7 @@ struct olevariantdata { https://github.com/ruby/ruby/blob/trunk/ext/win32ole/win32ole_variant.h#L7
 };
 
 VALUE cWIN32OLE_VARIANT;
-void Init_win32ole_variant();
+void Init_win32ole_variant(void);
 
 #endif
 
Index: ext/json/generator/generator.h
===================================================================
--- ext/json/generator/generator.h	(revision 47792)
+++ ext/json/generator/generator.h	(revision 47793)
@@ -109,7 +109,7 @@ static VALUE mFalseClass_to_json(int arg https://github.com/ruby/ruby/blob/trunk/ext/json/generator/generator.h#L109
 static VALUE mNilClass_to_json(int argc, VALUE *argv, VALUE self);
 static VALUE mObject_to_json(int argc, VALUE *argv, VALUE self);
 static void State_free(JSON_Generator_State *state);
-static JSON_Generator_State *State_allocate();
+static JSON_Generator_State *State_allocate(void);
 static VALUE cState_s_allocate(VALUE klass);
 static VALUE cState_configure(VALUE self, VALUE opts);
 static VALUE cState_to_h(VALUE self);
Index: ext/json/parser/parser.h
===================================================================
--- ext/json/parser/parser.h	(revision 47792)
+++ ext/json/parser/parser.h	(revision 47793)
@@ -68,7 +68,7 @@ static char *JSON_parse_string(JSON_Pars https://github.com/ruby/ruby/blob/trunk/ext/json/parser/parser.h#L68
 static VALUE convert_encoding(VALUE source);
 static VALUE cParser_initialize(int argc, VALUE *argv, VALUE self);
 static VALUE cParser_parse(VALUE self);
-static JSON_Parser *JSON_allocate();
+static JSON_Parser *JSON_allocate(void);
 static void JSON_mark(JSON_Parser *json);
 static void JSON_free(JSON_Parser *json);
 static VALUE cJSON_parser_s_allocate(VALUE klass);
Index: ext/tk/stubs.h
===================================================================
--- ext/tk/stubs.h	(revision 47792)
+++ ext/tk/stubs.h	(revision 47793)
@@ -1,15 +1,15 @@ https://github.com/ruby/ruby/blob/trunk/ext/tk/stubs.h#L1
 #include <tcl.h>
 
 extern int ruby_open_tcl_dll(char *);
-extern int ruby_open_tk_dll();
+extern int ruby_open_tk_dll(void);
 extern int ruby_open_tcltk_dll(char *);
-extern int tcl_stubs_init_p();
-extern int tk_stubs_init_p();
+extern int tcl_stubs_init_p(void);
+extern int tk_stubs_init_p(void);
 extern Tcl_Interp *ruby_tcl_create_ip_and_stubs_init(int*);
-extern int ruby_tcl_stubs_init();
+extern int ruby_tcl_stubs_init(void);
 extern int ruby_tk_stubs_init(Tcl_Interp*);
 extern int ruby_tk_stubs_safeinit(Tcl_Interp*);
-extern int ruby_tcltk_stubs();
+extern int ruby_tcltk_stubs(void);
 
 /* no error */
 #define TCLTK_STUBS_OK     (0)
Index: ext/tk/tcltklib.c
===================================================================
--- ext/tk/tcltklib.c	(revision 47792)
+++ ext/tk/tcltklib.c	(revision 47793)
@@ -21,7 +21,7 @@ https://github.com/ruby/ruby/blob/trunk/ext/tk/tcltklib.c#L21
 
 #ifdef HAVE_RB_THREAD_CHECK_TRAP_PENDING
 static int rb_thread_critical; /* dummy */
-int rb_thread_check_trap_pending();
+int rb_thread_check_trap_pending(void);
 #else
 /* use rb_thread_critical on Ruby 1.8.x */
 #include "rubysig.h"
Index: ext/psych/psych_parser.h
===================================================================
--- ext/psych/psych_parser.h	(revision 47792)
+++ ext/psych/psych_parser.h	(revision 47793)
@@ -1,6 +1,6 @@ https://github.com/ruby/ruby/blob/trunk/ext/psych/psych_parser.h#L1
 #ifndef PSYCH_PARSER_H
 #define PSYCH_PARSER_H
 
-void Init_psych_parser();
+void Init_psych_parser(void);
 
 #endif
Index: ext/psych/psych_emitter.h
===================================================================
--- ext/psych/psych_emitter.h	(revision 47792)
+++ ext/psych/psych_emitter.h	(revision 47793)
@@ -3,6 +3,6 @@ https://github.com/ruby/ruby/blob/trunk/ext/psych/psych_emitter.h#L3
 
 #include <psych.h>
 
-void Init_psych_emitter();
+void Init_psych_emitter(void);
 
 #endif
Index: ext/fiddle/closure.h
===================================================================
--- ext/fiddle/closure.h	(revision 47792)
+++ ext/fiddle/closure.h	(revision 47793)
@@ -3,6 +3,6 @@ https://github.com/ruby/ruby/blob/trunk/ext/fiddle/closure.h#L3
 
 #include <fiddle.h>
 
-void Init_fiddle_closure();
+void Init_fiddle_closure(void);
 
 #endif
Index: ext/fiddle/function.h
===================================================================
--- ext/fiddle/function.h	(revision 47792)
+++ ext/fiddle/function.h	(revision 47793)
@@ -3,6 +3,6 @@ https://github.com/ruby/ruby/blob/trunk/ext/fiddle/function.h#L3
 
 #include <fiddle.h>
 
-void Init_fiddle_function();
+void Init_fiddle_function(void);
 
 #endif

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

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