[#2577] how to check if ruby method is defined — Kikutani Makoto <kikutani@...>

きくたにです。

13 messages 1998/05/07

[#2608] experimental release ruby 1.1b9_19 — matz@... (Yukihiro Matsumoto)

まつもと ゆきひろです

30 messages 1998/05/13
[#2610] Re: experimental release ruby 1.1b9_19 — 藤本尚邦 / FUJIMOTO Hisakuni <hisa@...> 1998/05/13

藤本です、こんにちは。

[#2614] Re: experimental release ruby 1.1b9_19 — matz@... (Yukihiro Matsumoto) 1998/05/14

まつもと ゆきひろです

[#2622] Re: experimental release ruby 1.1b9_19 — 藤本尚邦 / FUJIMOTO Hisakuni <hisa@...> 1998/05/14

藤本です、こんにちは。

[#2623] Re: experimental release ruby 1.1b9_19 — matz@... (Yukihiro Matsumoto) 1998/05/14

まつもと ゆきひろです

[#2664] [BUG] b = proc{binding}.call — keiju@... (Keiju ISHITSUKA)

けいじゅ@日本ラショナルソフトウェアです.

13 messages 1998/05/18
[#2665] Re: [BUG] b = proc{binding}.call — matz@... (Yukihiro Matsumoto) 1998/05/18

まつもと ゆきひろです

[#2721] convert Perl's t/regexp.t to ruby — Inaba Hiroto <inaba@...>

ruby-list の regexp difference with perl のスレッドを読んでいて思いつ

22 messages 1998/05/20
[#2727] Re: convert Perl's t/regexp.t to ruby — matz@... (Yukihiro Matsumoto) 1998/05/22

まつもと ゆきひろです

[#2728] Re: convert Perl's t/regexp.t to ruby — Inaba Hiroto <inaba@...> 1998/05/22

t/regexp.tではなくてt/op/regexp.tでした。

[#2740] Re: convert Perl's t/regexp.t to ruby — matz@... (Yukihiro Matsumoto) 1998/05/25

まつもと ゆきひろです

[#2747] Re: convert Perl's t/regexp.t to ruby — Inaba Hiroto <inaba@...> 1998/05/25

From: matz@netlab.co.jp (Yukihiro Matsumoto)

[#2769] Re: convert Perl's t/regexp.t to ruby — Inaba Hiroto <inaba@...> 1998/05/27

From: Inaba Hiroto <inaba@st.rim.or.jp>

[#2773] Re: convert Perl's t/regexp.t to ruby — matz@... (Yukihiro Matsumoto) 1998/05/28

まつもと ゆきひろです

[#2778] Re: convert Perl's t/regexp.t to ruby — Inaba Hiroto <inaba@...> 1998/05/28

From: matz@netlab.co.jp (Yukihiro Matsumoto)

[#2785] Re: convert Perl's t/regexp.t to ruby — matz@... (Yukihiro Matsumoto) 1998/05/29

まつもと ゆきひろです

[#2790] Re: convert Perl's t/regexp.t to ruby — Inaba Hiroto <inaba@...> 1998/05/30

From: matz@netlab.co.jp (Yukihiro Matsumoto)

[#2795] Re: convert Perl's t/regexp.t to ruby — matz@... (Yukihiro Matsumoto) 1998/06/01

まつもと ゆきひろです

[ruby-dev:2609] Ruby for BeOS (Re: experimental release ruby 1.1b9_19)

From: "MAEDA Shugo" <shugo@...>
Date: 1998-05-13 11:06:17 UTC
List: ruby-dev #2609
前田です。

matz@netlab.co.jp (Yukihiro Matsumoto) wrote:

>今回の大きな修正は
>
>  * SyntaxErrorがStringのままだった
>  * INT,UINT,UCHAR,USHORTの追放
>  * BeOS/MacOSパッチの一部取り込み
>
>です.BeOS/MacOSパッチはパス区切り文字などをできれば"/"に統
>一したいのでその関係と,あと動作がよく分からないものをはずし
>てます.今回は変更が広範囲に及ぶので信頼性は低いかも知れませ
>ん(こんなのばっかり).

BeOS対応で何箇所か変更しなければいけない所がありました。

1. Intel版のためのconfig.guessの変更
2. BeOS R3 でFILE構造体のメンバがstate->_stateに変更になっているので
   io.cの変更
3. error.cでsyserr_list関連の対応
4. util.cでmktempを使っているためstdio.hをインクルード

うちのCodeWarriorではリンカに制限があるので、動作確認はできないのですが、
一応パッチを付けておきます。

--
前田 修吾

Attachments (2)

ruby-beos.diff (2.33 KB, text/x-diff)
--- config.guess.orig	Wed May 13 18:58:26 1998
+++ config.guess	Wed May 13 19:05:20 1998
@@ -737,6 +737,9 @@
     BeMac:BeOS:*:*)
         echo powerpc-apple-beos
 	exit 0 ;;
+    BePC:BeOS:*:*)
+	echo i586-pc-beos
+	exit 0 ;;
 esac
 
 #echo '(No uname command or uname output not recognized.)' 1>&2
--- io.c.orig	Wed May 13 19:09:44 1998
+++ io.c	Wed May 13 19:10:15 1998
@@ -99,7 +99,7 @@
 #    define READ_DATA_PENDING(fp) ((fp)->FILE_COUNT > 0)
 #  else
 #    if defined(__BEOS__)
-#      define ReadDataPending(fp) (fp->state._eof == 0)
+#      define ReadDataPending(fp) (fp->_state._eof == 0)
 #    elif defined(USE_CWGUSI)
 #      define ReadDataPending(fp) (fp->state.eof == 0)
 #    else
--- error.c.orig	Wed May 13 19:20:56 1998
+++ error.c	Wed May 13 19:36:45 1998
@@ -478,11 +478,29 @@
     int i;
     char *name;
 {
+#ifdef __BEOS__
+   VALUE *list;
+   int ix, offset;
+#endif
     VALUE error = rb_define_class_under(mErrno, name, eSystemCallError);
     rb_define_const(error, "Errno", INT2FIX(i));
+#ifdef __BEOS__
+   i -= B_GENERAL_ERROR_BASE;
+   ix = (i >> 12) & 0xf;
+   offset = (i >> 8) & 0xf;
+   if (offset < syserr_index[ix].n) {
+      ix = syserr_index[ix].ix;
+      if ((i & 0xff) < syserr_list[ix + offset].n) {
+	 list = syserr_list[ix + offset].list;
+	 list[i & 0xff] = error;
+	 rb_global_variable(&list[i & 0xff]);
+      }
+   }
+#else
     if (i <= sys_nerr) {
 	syserr_list[i] = error;
     }
+#endif
     return error;
 }
 
@@ -711,12 +729,24 @@
 static void
 init_syserr()
 {
+#ifdef __BEOS__
+   int i, ix, offset;
+#endif
     eSystemCallError = rb_define_class("SystemCallError", eStandardError);
     rb_define_method(eSystemCallError, "errno", syserr_errno, 0);
 
     mErrno = rb_define_module("Errno");
+#ifdef __BEOS__
+   for (i = 0; syserr_index[i].n != 0; i++) {
+      ix = syserr_index[i].ix;
+      for (offset = 0; offset < syserr_index[i].n; offset++) {
+	 MEMZERO(syserr_list[ix + offset].list, VALUE, syserr_list[ix + offset].n);
+      }
+   }
+#else
     syserr_list = ALLOC_N(VALUE, sys_nerr+1);
     MEMZERO(syserr_list, VALUE, sys_nerr+1);
+#endif
 
 #ifdef EPERM
     set_syserr(EPERM, "EPERM");
--- util.c.orig	Wed May 13 19:45:06 1998
+++ util.c	Wed May 13 19:45:19 1998
@@ -10,6 +10,8 @@
 
 ************************************************/
 
+#include <stdio.h>
+
 #define RUBY_NO_INLINE
 #include "ruby.h"
 
ruby-beos.diff (33 Bytes, application/x-be_attribute)

In This Thread

Prev Next