[#3450] [irb:BUG] i=0; i %2 — GOTO Kentaro <gotoken@...>
ごとけんです
6 messages
1998/08/15
[#3456] ioctl & thread (Re: [ruby-list:9173] Re: gtk) — "D.Kanda" <MAP2303@...>
4 messages
1998/08/17
[#3461] Exception — keiju@... (Keiju ISHITSUKA)
けいじゅ@日本ラショナルソフトウェアです.
10 messages
1998/08/24
[#3466] Re: Exception
— matz@... (Yukihiro Matsumoto)
1998/08/24
まつもと ゆきひろです
[#3462] [BUG?] open()'s command line interpretation — Shin-ichro Hara <sinara@...>
原です。
7 messages
1998/08/24
[#3463] Re: [BUG?] open()'s command line interpretation
— WATANABE Hirofumi <watanabe@...>
1998/08/24
わたなべです.
[#3471] Re: [BUG?] open()'s command line interpretation
— matz@... (Yukihiro Matsumoto)
1998/08/25
まつもと ゆきひろです
[#3464] [BUG] ENV[] = nil / cygwin32 — Shin-ichro Hara <sinara@...>
原です。
6 messages
1998/08/24
[#3484] [BUG] Array#hash — keiju@... (Keiju ISHITSUKA)
けいじゅ@日本ラショナルソフトウェアです.
5 messages
1998/08/26
[#3494] [BUG] gets() blocks at the last line /CYGWIN32 — Shin-ichro Hara <sinara@...>
原です。
5 messages
1998/08/26
[ruby-dev:3499] order of require specified -r option
From:
Hiroshi Igarashi <igarashi@...>
Date:
1998-08-28 02:35:31 UTC
List:
ruby-dev #3499
五十嵐です。
コマンドラインオプションの-rについてです。
現状だと複数の-rで指定されたファイル名がstack的に保存されていて
iga@runal> cat t1.rb
print("t1 loaded\n")
iga@runal> cat t2.rb
print("t2 loaded\n")
iga@runal> ruby -r t1 -r t2 -e ''
t2 loaded
t1 loaded
となるので、指定順にrequireされるようにしてみました。
仕様では特に規定されていないみたいですが。
#最近Cを使っていないのでコードが変かもしれません。
--- ruby.c.orig Mon Aug 24 12:18:20 1998
+++ ruby.c Mon Aug 24 13:19:24 1998
@@ -134,7 +134,8 @@
struct req_list {
char *name;
struct req_list *next;
-} *req_list;
+} req_list_head;
+struct req_list *req_list_last = &req_list_head;
static void
add_modules(mod)
@@ -144,17 +145,18 @@
list = ALLOC(struct req_list);
list->name = mod;
- list->next = req_list;
- req_list = list;
+ list->next = 0;
+ req_list_last->next = list;
+ req_list_last = list;
}
void
ruby_require_modules()
{
- struct req_list *list = req_list;
+ struct req_list *list = req_list_head.next;
struct req_list *tmp;
- req_list = 0;
+ req_list_last = 0;
while (list) {
f_require(Qnil, str_new2(list->name));
tmp = list->next;