From 5540c1de81f69e160c2302e56e4957147f240450 Mon Sep 17 00:00:00 2001 From: nobu Date: Sat, 4 Oct 2014 23:09:32 +0000 Subject: ext: protoize no-arguments functions git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@47792 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- ext/json/generator/generator.c | 4 ++-- ext/json/parser/parser.c | 4 ++-- ext/openssl/ossl_pkey_ec.c | 4 ++-- ext/psych/psych.c | 2 +- ext/psych/psych_emitter.c | 2 +- ext/psych/psych_parser.c | 2 +- ext/syslog/syslog.c | 2 +- ext/win32ole/win32ole_method.c | 2 +- ext/win32ole/win32ole_type.c | 2 +- ext/win32ole/win32ole_variable.c | 2 +- 10 files changed, 13 insertions(+), 13 deletions(-) (limited to 'ext') diff --git a/ext/json/generator/generator.c b/ext/json/generator/generator.c index 1b9652df24..b9f10171c8 100644 --- a/ext/json/generator/generator.c +++ b/ext/json/generator/generator.c @@ -499,7 +499,7 @@ static void State_free(JSON_Generator_State *state) ruby_xfree(state); } -static JSON_Generator_State *State_allocate() +static JSON_Generator_State *State_allocate(void) { JSON_Generator_State *state = ALLOC(JSON_Generator_State); MEMZERO(state, JSON_Generator_State, 1); @@ -1327,7 +1327,7 @@ static VALUE cState_buffer_initial_length_set(VALUE self, VALUE buffer_initial_l /* * */ -void Init_generator() +void Init_generator(void) { rb_require("json/common"); diff --git a/ext/json/parser/parser.c b/ext/json/parser/parser.c index 29335541d4..a8b606981c 100644 --- a/ext/json/parser/parser.c +++ b/ext/json/parser/parser.c @@ -2092,7 +2092,7 @@ static VALUE cParser_parse(VALUE self) } -static JSON_Parser *JSON_allocate() +static JSON_Parser *JSON_allocate(void) { JSON_Parser *json = ALLOC(JSON_Parser); MEMZERO(json, JSON_Parser, 1); @@ -2145,7 +2145,7 @@ static VALUE cParser_quirks_mode_p(VALUE self) } -void Init_parser() +void Init_parser(void) { rb_require("json/common"); mJSON = rb_define_module("JSON"); diff --git a/ext/openssl/ossl_pkey_ec.c b/ext/openssl/ossl_pkey_ec.c index 5e419bd167..cec0059715 100644 --- a/ext/openssl/ossl_pkey_ec.c +++ b/ext/openssl/ossl_pkey_ec.c @@ -1556,7 +1556,7 @@ static void no_copy(VALUE klass) rb_undef_method(klass, "initialize_copy"); } -void Init_ossl_ec() +void Init_ossl_ec(void) { #ifdef DONT_NEED_RDOC_WORKAROUND mOSSL = rb_define_module("OpenSSL"); @@ -1677,7 +1677,7 @@ void Init_ossl_ec() } #else /* defined NO_EC */ -void Init_ossl_ec() +void Init_ossl_ec(void) { } #endif /* NO_EC */ diff --git a/ext/psych/psych.c b/ext/psych/psych.c index 69ff1d8dfc..3bb59bfc11 100644 --- a/ext/psych/psych.c +++ b/ext/psych/psych.c @@ -20,7 +20,7 @@ static VALUE libyaml_version(VALUE module) VALUE mPsych; -void Init_psych() +void Init_psych(void) { mPsych = rb_define_module("Psych"); diff --git a/ext/psych/psych_emitter.c b/ext/psych/psych_emitter.c index f0d032649c..d833b59c06 100644 --- a/ext/psych/psych_emitter.c +++ b/ext/psych/psych_emitter.c @@ -504,7 +504,7 @@ static VALUE set_line_width(VALUE self, VALUE width) return width; } -void Init_psych_emitter() +void Init_psych_emitter(void) { VALUE psych = rb_define_module("Psych"); VALUE handler = rb_define_class_under(psych, "Handler", rb_cObject); diff --git a/ext/psych/psych_parser.c b/ext/psych/psych_parser.c index 8c65ce1307..19c7484124 100644 --- a/ext/psych/psych_parser.c +++ b/ext/psych/psych_parser.c @@ -535,7 +535,7 @@ static VALUE mark(VALUE self) return rb_class_new_instance(3, args, mark_klass); } -void Init_psych_parser() +void Init_psych_parser(void) { #if 0 mPsych = rb_define_module("Psych"); diff --git a/ext/syslog/syslog.c b/ext/syslog/syslog.c index 8ef722e1c0..6aa2cd8484 100644 --- a/ext/syslog/syslog.c +++ b/ext/syslog/syslog.c @@ -418,7 +418,7 @@ static VALUE mSyslogMacros_included(VALUE mod, VALUE target) * * The syslog protocol is standardized in RFC 5424. */ -void Init_syslog() +void Init_syslog(void) { mSyslog = rb_define_module("Syslog"); diff --git a/ext/win32ole/win32ole_method.c b/ext/win32ole/win32ole_method.c index 051ba429c9..4d3a398b14 100644 --- a/ext/win32ole/win32ole_method.c +++ b/ext/win32ole/win32ole_method.c @@ -901,7 +901,7 @@ folemethod_inspect(VALUE self) return default_inspect(self, "WIN32OLE_METHOD"); } -void Init_win32ole_method() +void Init_win32ole_method(void) { cWIN32OLE_METHOD = rb_define_class("WIN32OLE_METHOD", rb_cObject); rb_define_alloc_func(cWIN32OLE_METHOD, folemethod_s_allocate); diff --git a/ext/win32ole/win32ole_type.c b/ext/win32ole/win32ole_type.c index c5ae53c3aa..48df6707e8 100644 --- a/ext/win32ole/win32ole_type.c +++ b/ext/win32ole/win32ole_type.c @@ -883,7 +883,7 @@ foletype_inspect(VALUE self) return default_inspect(self, "WIN32OLE_TYPE"); } -void Init_win32ole_type() +void Init_win32ole_type(void) { cWIN32OLE_TYPE = rb_define_class("WIN32OLE_TYPE", rb_cObject); rb_define_singleton_method(cWIN32OLE_TYPE, "ole_classes", foletype_s_ole_classes, 1); diff --git a/ext/win32ole/win32ole_variable.c b/ext/win32ole/win32ole_variable.c index 85f3341f98..fb67fdd0fc 100644 --- a/ext/win32ole/win32ole_variable.c +++ b/ext/win32ole/win32ole_variable.c @@ -351,7 +351,7 @@ folevariable_inspect(VALUE self) return make_inspect("WIN32OLE_VARIABLE", detail); } -void Init_win32ole_variable() +void Init_win32ole_variable(void) { cWIN32OLE_VARIABLE = rb_define_class("WIN32OLE_VARIABLE", rb_cObject); rb_define_method(cWIN32OLE_VARIABLE, "name", folevariable_name, 0); -- cgit v1.2.3