[前][次][番号順一覧][スレッド一覧][生データ]

yarv-diff:197

From: ko1 atdot.net
Date: 9 Jan 2006 01:26:41 -0000
Subject: [yarv-diff:197] r355 - trunk

Author: aamine
Date: 2006-01-09 10:26:41 +0900 (Mon, 09 Jan 2006)
New Revision: 355

Modified:
   trunk/ChangeLog
   trunk/compile.c
   trunk/eval_thread.c
   trunk/yarvcore.c
Log:
* eval_thread.c: rb_thread_join is required to build ruby on Linux.
* compile.c: unify coding style.
* yarvcore.c: ditto.


Modified: trunk/ChangeLog
===================================================================
--- trunk/ChangeLog	2006-01-06 00:24:28 UTC (rev 354)
+++ trunk/ChangeLog	2006-01-09 01:26:41 UTC (rev 355)
@@ -4,6 +4,16 @@
 #  from Mon, 03 May 2004 01:24:19 +0900
 #
 
+2006-01-09(Mon) 10:25:12 +0900  Minero Aoki  <aamine loveruby.net>
+
+	* eval_thread.c: rb_thread_join is required to build ruby on
+	  Linux.
+
+	* compile.c: unify coding style.
+
+	* yarvcore.c: ditto.
+
+
 2006-01-06(Fri) 09:21:34 +0900  Minero Aoki  <aamine loveruby.net>
 
 	* vm.c: coding style change only.

Modified: trunk/compile.c
===================================================================
--- trunk/compile.c	2006-01-06 00:24:28 UTC (rev 354)
+++ trunk/compile.c	2006-01-09 01:26:41 UTC (rev 355)
@@ -6,9 +6,9 @@
  */
 
 
-#include <ruby.h>
-#include <node.h>
-#include <env.h>
+#include "ruby.h"
+#include "node.h"
+#include "env.h"
 
 #include "yarvcore.h"
 #include "compile.h"
@@ -111,13 +111,15 @@
 static int set_optargs_table(yarv_iseq_t *iseq);
 
 static int
-iseq_add_mark_object(yarv_iseq_t *iseq, VALUE v){
+iseq_add_mark_object(yarv_iseq_t *iseq, VALUE v)
+{
   rb_ary_push(iseq->iseq_mark_ary, v);
   return COMPILE_OK;
 }
 
 static int
-iseq_add_mark_object_compile_time(yarv_iseq_t *iseq, VALUE v){
+iseq_add_mark_object_compile_time(yarv_iseq_t *iseq, VALUE v)
+{
   rb_ary_push(iseq->compile_data->mark_ary, v);
   return COMPILE_OK;
 }
@@ -4334,7 +4336,8 @@
 }
 
 static void
-dump_disasm_anchor(LINK_ANCHOR *anc){
+dump_disasm_anchor(LINK_ANCHOR *anc)
+{
   dump_disasm_list(FIRST_ELEMENT(anc));
 }
 
@@ -4383,7 +4386,7 @@
 }
 
 VALUE
-insns_name_array()
+insns_name_array(void)
 {
   VALUE ary = rb_ary_new();
   int i;
@@ -4392,4 +4395,3 @@
   }
   return ary;
 }
-

Modified: trunk/eval_thread.c
===================================================================
--- trunk/eval_thread.c	2006-01-06 00:24:28 UTC (rev 354)
+++ trunk/eval_thread.c	2006-01-09 01:26:41 UTC (rev 355)
@@ -774,6 +774,12 @@
   return 0;
 }
 
+static int
+rb_thread_join(rb_thread_t th, double limit)
+{
+    return Qtrue;
+}
+
 /*
  *  call-seq:
  *     thr.join          => thr

Modified: trunk/yarvcore.c
===================================================================
--- trunk/yarvcore.c	2006-01-06 00:24:28 UTC (rev 354)
+++ trunk/yarvcore.c	2006-01-09 01:26:41 UTC (rev 355)
@@ -5,11 +5,11 @@
  * $Id$
  * Create : K.S. 04/01/01 01:17:22
  *
- * Copyright (c) 2004 SASADA Koichi <ko1 at atdot.net>
+ * Copyright (c) 2004-2006 SASADA Koichi <ko1 at atdot.net>
  */
 
-#include <ruby.h>
-#include <node.h>
+#include "ruby.h"
+#include "node.h"
 
 #include "yarv_version.h"
 #include "yarvcore.h"
@@ -77,14 +77,16 @@
 static int g_indent = 0;
 
 static void
-gc_debug_indent(){
+gc_debug_indent(void)
+{
   int i;
   for(i=0; i<g_indent; i++){
     printf(" ");
   }
 }
 static void
-MARK_REPORT_BODY(char *msg, int st, void *ptr){
+MARK_REPORT_BODY(char *msg, int st, void *ptr)
+{
   if(st == 0){
     g_indent--;
   }
@@ -223,7 +225,7 @@
 }
 
 VALUE
-rb_backref_get()
+rb_backref_get(void)
 {
   VALUE *var = rb_svar(1);
   if (var) {
@@ -240,7 +242,7 @@
 }
 
 VALUE
-rb_lastline_get()
+rb_lastline_get(void)
 {
   VALUE *var = rb_svar(0);
   if (var) {
@@ -317,7 +319,8 @@
 }
 
 static VALUE
-yarvcore_parse(VALUE self, VALUE str, VALUE file, VALUE line){
+yarvcore_parse(VALUE self, VALUE str, VALUE file, VALUE line)
+{
   VALUE node = compile_string(str, file, line);
   return yarv_new_iseqval(node, rb_str_new2("<main>"), file, Qfalse, ISEQ_TYPE_TOP, Qfalse);
 }
@@ -329,7 +332,8 @@
 
 VALUE
 yarv_new_iseqval(VALUE node, VALUE name, VALUE file,
-                 VALUE parent, VALUE type, VALUE opt){
+                 VALUE parent, VALUE type, VALUE opt)
+{
   VALUE argv[6];
   
   argv[0] = node;
@@ -879,7 +883,8 @@
 }
 
 VALUE
-yarv_obj_is_proc(VALUE proc){
+yarv_obj_is_proc(VALUE proc)
+{
   if (TYPE(proc) == T_DATA &&
       RDATA(proc)->dfree == (RUBY_DATA_FUNC)proc_free){
     return Qtrue;
@@ -969,21 +974,24 @@
   return Qnil;
 }
 
-static VALUE cfunc(){
+static VALUE
+cfunc(void)
+{
   rb_funcall(Qnil, rb_intern("rfunc"), 0, 0);
   rb_funcall(Qnil, rb_intern("rfunc"), 0, 0);
   return Qnil;
 }
 
 // VALUE yarv_Hash_each();
-VALUE insns_name_array();
-VALUE Init_yarvthread();
+VALUE insns_name_array(void);
+VALUE Init_yarvthread(void);
 extern VALUE *rb_gc_stack_start;
 
 VALUE rb_proc_s_new(int argc, VALUE *argv, VALUE klass);
 
 VALUE
-sdr(){
+sdr(void)
+{
   yarv_bug();
   return Qnil;
 }
@@ -1027,9 +1035,9 @@
 #endif
 ;
 
-
-void Init_yarvcore(){
-
+void
+Init_yarvcore(void)
+{
 #include "rev.inc"
 
   snprintf(yarv_version, 0x20, "YARVCore %d.%d.%d", MAJOR_VER, MINOR_VER, DEVEL_VER);
@@ -1186,7 +1194,7 @@
 }
 
 static void
-test()
+test(void)
 {
   int i; int *p;
   printf("!test!\n");
@@ -1196,11 +1204,10 @@
 }
 
 void
-Init_yarv()
+Init_yarv(void)
 {
   /* initialize main thread */
   yarv_thread_t *th = ALLOC(yarv_thread_t);
   th_init2(th);
   yarv_set_current_running_thread_raw(th);
 }
-


-- 
ML: yarv-diff quickml.atdot.net
Info: http://www.atdot.net/~ko1/quickml

[前][次][番号順一覧][スレッド一覧][生データ]