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

ruby-changes:24030

From: nobu <ko1@a...>
Date: Thu, 14 Jun 2012 12:03:59 +0900 (JST)
Subject: [ruby-changes:24030] nobu:r36081 (trunk): fix r36079

nobu	2012-06-14 12:03:48 +0900 (Thu, 14 Jun 2012)

  New Revision: 36081

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

  Log:
    fix r36079
    
    * include/ruby/ruby.h: public symbols must have default visibility.

  Modified files:
    trunk/eval.c
    trunk/include/ruby/ruby.h
    trunk/nacl/pepper_main.c
    trunk/ruby.c
    trunk/vm_core.h

Index: include/ruby/ruby.h
===================================================================
--- include/ruby/ruby.h	(revision 36080)
+++ include/ruby/ruby.h	(revision 36081)
@@ -1464,10 +1464,6 @@
 PRINTF_ARGS(int ruby_snprintf(char *str, size_t n, char const *fmt, ...), 3, 4);
 int ruby_vsnprintf(char *str, size_t n, char const *fmt, va_list ap);
 
-#if defined __GNUC__ && __GNUC__ >= 4
-#pragma GCC visibility pop
-#endif
-
 #ifndef RUBY_DONT_SUBST
 #include "ruby/subst.h"
 #endif
@@ -1488,7 +1484,7 @@
  */
 typedef void *ruby_opaque_t;
 
-/*! @deprecated You no longer need to use this macro. */ 
+/*! @deprecated You no longer need to use this macro. */
 #if (defined(__APPLE__) || defined(__NeXT__)) && defined(__MACH__)
 #define RUBY_GLOBAL_SETUP /* use linker option to link startup code with ObjC support */
 #else
@@ -1555,6 +1551,10 @@
 
 /*! @} */
 
+#if defined __GNUC__ && __GNUC__ >= 4
+#pragma GCC visibility pop
+#endif
+
 #if defined(__cplusplus)
 #if 0
 { /* satisfy cc-mode */
Index: vm_core.h
===================================================================
--- vm_core.h	(revision 36080)
+++ vm_core.h	(revision 36081)
@@ -459,7 +459,7 @@
     struct rb_vm_protect_tag *protect_tag;
 
     /*! Thread-local state of evaluation context.
-     * 
+     *
      *  If negative, this thread is evaluating the main program.
      *  If positive, this thread is evaluating a program under Kernel::eval
      *  family.
Index: eval.c
===================================================================
--- eval.c	(revision 36080)
+++ eval.c	(revision 36081)
@@ -283,7 +283,7 @@
 	});
     }
     POP_TAG();
-    *result = state ? th->errinfo : retval; 
+    *result = state ? th->errinfo : retval;
     return state;
 }
 
Index: nacl/pepper_main.c
===================================================================
--- nacl/pepper_main.c	(revision 36080)
+++ nacl/pepper_main.c	(revision 36081)
@@ -265,8 +265,8 @@
 
 static struct PP_Var
 pruby_obj_to_var(volatile VALUE obj)
-{ 
-  static const char* const error = 
+{
+  static const char* const error =
       "throw 'Failed to convert the result to a JavaScript object';";
   int state;
   obj = rb_protect(&rb_obj_as_string, obj, &state);
@@ -318,7 +318,7 @@
   /* PPAPI main thread */
   struct PepperInstance* const instance = (struct PepperInstance*)data;
   const char* const msg = (const char*)instance->async_call_args;
-  messaging_interface->PostMessage(instance->instance, 
+  messaging_interface->PostMessage(instance->instance,
                                    pruby_cstr_to_var(msg));
 }
 
@@ -445,7 +445,7 @@
   pthread_mutex_unlock(&instance->mutex);
 
   if (!state) {
-      instance->async_call_args = 
+      instance->async_call_args =
           rb_str_concat(rb_usascii_str_new_cstr("return:"),
                         rb_obj_as_string(result));
       core_interface->CallOnMainThread(
@@ -805,7 +805,7 @@
 {
   struct PepperInstance* const instance = (struct PepperInstance*)data;
   if (result > 0) {
-    rb_str_buf_cat(instance->async_call_result.as_value, 
+    rb_str_buf_cat(instance->async_call_result.as_value,
                    instance->buf, result);
     loader_interface->ReadResponseBody(
         instance->url_loader, instance->buf, 1000, PP_MakeCompletionCallback(load_file_read_contents_callback, instance));
@@ -868,7 +868,7 @@
   }
   else if (RB_TYPE_P(instance->async_call_result.as_value, T_STRING)) {
     VALUE str = instance->async_call_result.as_value;
-    extern void* rb_compile_cstr(const char *f, const char *s, int len, int line); 
+    extern void* rb_compile_cstr(const char *f, const char *s, int len, int line);
     return rb_compile_cstr(path, RSTRING_PTR(str), RSTRING_LEN(str), 0);
   }
   else {
Index: ruby.c
===================================================================
--- ruby.c	(revision 36080)
+++ ruby.c	(revision 36081)
@@ -1753,7 +1753,7 @@
  * @li loads the file specified by path.
  * @li parses the source and compiles it
  *
- * @param fname <code>$0</code> is set to this value. 
+ * @param fname <code>$0</code> is set to this value.
  *              If nil,
  *              uses the given path instead.
  * @param path path to the source
@@ -1776,7 +1776,7 @@
  *
  * This function parses the given source and compiles it
  *
- * @param fname <code>$0</code> is set to this value. 
+ * @param fname <code>$0</code> is set to this value.
  * @param source Ruby source string
  * @param error where to store the exception if an error occured.
  * @return The compiled source code. Or NULL if an error occured.

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

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