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

ruby-changes:29782

From: nobu <ko1@a...>
Date: Mon, 8 Jul 2013 23:12:40 +0900 (JST)
Subject: [ruby-changes:29782] nobu:r41834 (trunk): win32: for strict ANSI

nobu	2013-07-08 23:12:26 +0900 (Mon, 08 Jul 2013)

  New Revision: 41834

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

  Log:
    win32: for strict ANSI
    
    * thread_win32.c (w32_thread_start_func, thread_start_func_1),
      (timer_thread_func): use __stdcall instead of _stdcall which is
      unavailable in strict ANSI mode.  [ruby-core:55312] [Bug #8495]
    * win32/win32.c (gettimeofday): use __cdecl instead of _cdecl.

  Modified files:
    trunk/ChangeLog
    trunk/thread_win32.c
    trunk/win32/win32.c

Index: thread_win32.c
===================================================================
--- thread_win32.c	(revision 41833)
+++ thread_win32.c	(revision 41834)
@@ -269,7 +269,7 @@ w32_resume_thread(HANDLE handle) https://github.com/ruby/ruby/blob/trunk/thread_win32.c#L269
 #ifdef HAVE__BEGINTHREADEX
 #define start_thread (HANDLE)_beginthreadex
 #define thread_errno errno
-typedef unsigned long (_stdcall *w32_thread_start_func)(void*);
+typedef unsigned long (__stdcall *w32_thread_start_func)(void*);
 #else
 #define start_thread CreateThread
 #define thread_errno rb_w32_map_errno(GetLastError())
@@ -587,7 +587,7 @@ native_thread_destroy(rb_thread_t *th) https://github.com/ruby/ruby/blob/trunk/thread_win32.c#L587
     w32_close_handle(intr);
 }
 
-static unsigned long _stdcall
+static unsigned long __stdcall
 thread_start_func_1(void *th_ptr)
 {
     rb_thread_t *th = th_ptr;
@@ -695,7 +695,7 @@ ubf_handle(void *ptr) https://github.com/ruby/ruby/blob/trunk/thread_win32.c#L695
 static HANDLE timer_thread_id = 0;
 static HANDLE timer_thread_lock;
 
-static unsigned long _stdcall
+static unsigned long __stdcall
 timer_thread_func(void *dummy)
 {
     thread_debug("timer_thread\n");
Index: ChangeLog
===================================================================
--- ChangeLog	(revision 41833)
+++ ChangeLog	(revision 41834)
@@ -1,3 +1,11 @@ https://github.com/ruby/ruby/blob/trunk/ChangeLog#L1
+Mon Jul  8 23:12:22 2013  Nobuyoshi Nakada  <nobu@r...>
+
+	* thread_win32.c (w32_thread_start_func, thread_start_func_1),
+	  (timer_thread_func): use __stdcall instead of _stdcall which is
+	  unavailable in strict ANSI mode.  [ruby-core:55312] [Bug #8495]
+
+	* win32/win32.c (gettimeofday): use __cdecl instead of _cdecl.
+
 Mon Jul  8 22:41:12 2013  Tanaka Akira  <akr@f...>
 
 	* bignum.c (bary_mul): Arguments for work memory added.
Index: win32/win32.c
===================================================================
--- win32/win32.c	(revision 41833)
+++ win32/win32.c	(revision 41834)
@@ -4274,7 +4274,7 @@ filetime_to_timeval(const FILETIME* ft, https://github.com/ruby/ruby/blob/trunk/win32/win32.c#L4274
 }
 
 /* License: Ruby's */
-int _cdecl
+int __cdecl
 gettimeofday(struct timeval *tv, struct timezone *tz)
 {
     FILETIME ft;

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

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