[#34911] erb still treats $KCODE — "Yusuke ENDOH" <mame@...>

遠藤です。

16 messages 2008/06/03

[#34923] open() and encodings — "NARUSE, Yui" <naruse@...>

成瀬です。

53 messages 2008/06/03
[#34924] Re: open() and encodings — Yukihiro Matsumoto <matz@...> 2008/06/04

まつもと ゆきひろです

[#34931] Re: open() and encodings — "NARUSE, Yui" <naruse@...> 2008/06/04

成瀬です。

[#34934] Re: open() and encodings — Yukihiro Matsumoto <matz@...> 2008/06/05

まつもと ゆきひろです

[#34935] Re: open() and encodings — "U.Nakamura" <usa@...> 2008/06/05

こんにちは、なかむら(う)です。

[#34936] Re: open() and encodings — Yukihiro Matsumoto <matz@...> 2008/06/05

まつもと ゆきひろです

[#34937] Re: open() and encodings — "U.Nakamura" <usa@...> 2008/06/05

こんにちは、なかむら(う)です。

[#34948] Re: open() and encodings — Hidetoshi NAGAI <nagai@...> 2008/06/05

永井@知能.九工大です.

[#34961] Re: open() and encodings — "NARUSE, Yui" <naruse@...> 2008/06/05

成瀬です。

[#34997] Re: [ruby-changes:5517] Ruby:r17021 (trunk): * vm_insnhelper.c, vm.c, proc.c (proc_call): allow call method with — SASADA Koichi <ko1@...>

 ささだです.

19 messages 2008/06/08
[#34998] Re: [ruby-changes:5517] Ruby:r17021 (trunk): * vm_insnhelper.c, vm.c, proc.c (proc_call): allow call method with — Yukihiro Matsumoto <matz@...> 2008/06/08

まつもと ゆきひろです

[#34999] Re: [ruby-changes:5517] Ruby:r17021 (trunk): * vm_insnhelper.c, vm.c, proc.c (proc_call): allow call method with — SASADA Koichi <ko1@...> 2008/06/08

 ささだです.

[#35000] Re: [ruby-changes:5517] Ruby:r17021 (trunk): * vm_insnhelper.c, vm.c, proc.c (proc_call): allow call method with — Yukihiro Matsumoto <matz@...> 2008/06/08

まつもと ゆきひろです

[#35001] Re: [ruby-changes:5517] Ruby:r17021 (trunk): * vm_insnhelper.c, vm.c, proc.c (proc_call): allow call method with — SASADA Koichi <ko1@...> 2008/06/08

 ささだです.

[#35003] Re: [ruby-changes:5517] Ruby:r17021 (trunk): * vm_insnhelper.c, vm.c, proc.c (proc_call): allow call method with — Yukihiro Matsumoto <matz@...> 2008/06/08

まつもと ゆきひろです

[#35007] Re: [ruby-changes:5517] Ruby:r17021 (trunk): * vm_insnhelper.c, vm.c, proc.c (proc_call): allow call method with — "Yusuke ENDOH" <mame@...> 2008/06/09

遠藤です。

[#35013] Re: [ruby-changes:5517] Ruby:r17021 (trunk): * vm_insnhelper.c, vm.c, proc.c (proc_call): allow call method with — Yukihiro Matsumoto <matz@...> 2008/06/09

まつもと ゆきひろです

[#35019] Re: [ruby-changes:5517] Ruby:r17021 (trunk): * vm_insnhelper.c, vm.c, proc.c (proc_call): allow call method with — "Yusuke ENDOH" <mame@...> 2008/06/09

遠藤です。

[#35021] Re: [ruby-changes:5517] Ruby:r17021 (trunk): * vm_insnhelper.c, vm.c, proc.c (proc_call): allow call method with — Yukihiro Matsumoto <matz@...> 2008/06/09

まつもと ゆきひろです

[#35020] Ruby 1.8.7-p17 has been released — "Akinori MUSHA" <knu@...>

 Ruby 1.8.7-p17 をリリースしました。

13 messages 2008/06/09

[#35044] deadlock detection for 1.9 — "Yusuke ENDOH" <mame@...>

遠藤です。

14 messages 2008/06/10

[#35108] Re: [ruby-list:44988] Re: 各ブランチの計画 — Urabe Shyouhei <shyouhei@...>

卜部です。

15 messages 2008/06/15

[#35200] Win32 Unicode console output — Tietew <tietew@...>

Tietew です。

22 messages 2008/06/22
[#35270] Re: Win32 Unicode console output — "NARUSE, Yui" <naruse@...> 2008/06/29

[#35226] [PATCH] freeze required_paths in gem_prelude.rb — "Keita Yamaguchi" <keita.yamaguchi@...>

山口と申します。

14 messages 2008/06/25
[#35228] Re: [PATCH] freeze required_paths in gem_prelude.rb — "Yusuke ENDOH" <mame@...> 2008/06/25

遠藤です。

[#35230] Re: [PATCH] freeze required_paths in gem_prelude.rb — Yukihiro Matsumoto <matz@...> 2008/06/25

まつもと ゆきひろです

[#35227] [Bug:trunk] Re: [ruby-cvs:24798] Ruby:r17573 (trunk): * parse.y (primary): make functional-style not operator to act — "U.Nakamura" <usa@...>

こんにちは、なかむら(う)です。

7 messages 2008/06/25

[#35247] Re: [ruby-list:45128] Re: Ruby 1.9.0/1.8.7/1.8.6/1.8.5 new releases (Security Fix) — Urabe Shyouhei <shyouhei@...>

卜部です。-devに振ります。ひょっとしてこんなパッチでSEGVのほうはおさまっ

13 messages 2008/06/26
[#35250] Re: [ruby-list:45128] Re: Ruby 1.9.0/1.8.7/1.8.6/1.8.5 new releases (Security Fix) — Yukihiro Matsumoto <matz@...> 2008/06/26

まつもと ゆきひろです

[#35273] $SAFEの今後 — Urabe Shyouhei <shyouhei@...>

〜これまでのあらすじ〜

24 messages 2008/06/30
[#35293] Re: $SAFEの今後 — Yukihiro Matsumoto <matz@...> 2008/07/01

まつもと ゆきひろです

[#35298] Re: $SAFEの今後 — Urabe Shyouhei <shyouhei@...> 2008/07/01

卜部です。

[#35303] Re: $SAFEの今後 — Yukihiro Matsumoto <matz@...> 2008/07/01

まつもと ゆきひろです

[#35304] Re: $SAFEの今後 — Urabe Shyouhei <shyouhei@...> 2008/07/01

卜部です。

[#35305] Re: $SAFEの今後 — Yukihiro Matsumoto <matz@...> 2008/07/01

まつもと ゆきひろです

[#35306] Re: $SAFEの今後 — "Shugo Maeda" <shugo@...> 2008/07/02

前田です。

[#35278] [BUG] test_win32ole_event.rb in trunk — Masaki Suketa <masaki.suketa@...>

助田です。

22 messages 2008/06/30
[#35281] Re: [BUG] test_win32ole_event.rb in trunk — "U.Nakamura" <usa@...> 2008/06/30

こんにちは、なかむら(う)です。

[#35282] Re: [BUG] test_win32ole_event.rb in trunk — arton <artonx@...> 2008/06/30

artonです。

[#35295] Re: [BUG] test_win32ole_event.rb in trunk — Masaki Suketa <masaki.suketa@...> 2008/07/01

助田です。

[ruby-dev:35111] Re: [ruby-list:44988] Re: 各ブランチの計画

From: "U.Nakamura" <usa@...>
Date: 2008-06-15 19:13:04 UTC
List: ruby-dev #35111
こんにちは、なかむら(う)です。

In message "[ruby-dev:35108] Re: [ruby-list:44988] Re:  各ブランチの計画"
    on Jun.16,2008 02:05:14, <shyouhei@ruby-lang.org> wrote:
| 一応、r16730(1.8.7のリリース)までの間に自分が「バックポートすべき」と
| 思ったチェンジセットは一通り当てた状態になりました。どうでしょう?
| しばらく様子をみますので、「あれが入ってない」とか「このプラットフォーム
| で動かない」とかありましたらご連絡ください。
| たぶん1.8.5は次のリリースが最後です。

mswin32で確認してみました。
ビルドおよびテストを通すためには以下のパッチが必要なようです。

mkmf.rbはr11195およびr11196です。

file.cは、パッチあてミスと思われるものを直したんですが、ruby_1_8
HEADを見ながら直したので、r16785を含んでしまっています。
あと、
  #define OpenFile rb_io_t
は意図的に入れられたような気もするんですが、これを削っちゃっ
たら他のプラットフォームでまずかったりするんでしょうか?
あるとmswin32ではビルドできなくなるので、必要ならもう一工夫し
ないといけません。

で、この他に2点気付いたことがあります。
  (1) lib/test/unitをruby_1_8 HEADと同じにしないと、runnerに
      ファイルを指定した場合に動かない
  (2) test/test_yaml.rbが2Eとなるが、ruby_1_8 HEADと同じにし
      ても直らないので原因がよくわからない(GC関連?)

Index: lib/mkmf.rb
===================================================================
--- lib/mkmf.rb	(revision 17351)
+++ lib/mkmf.rb	(working copy)
@@ -1483,9 +1483,8 @@ EXPORT_PREFIX = config_string('EXPORT_PR
 
 hdr = []
 config_string('COMMON_MACROS') do |s|
-  Shellwords.shellwords(s).each do |s|
-    /(.*?)(?:=(.*))/ =~ s
-    hdr << "#define #$1 #$2"
+  Shellwords.shellwords(s).each do |w|
+    hdr << "#define " + w.split(/=/, 2).join(" ")
   end
 end
 config_string('COMMON_HEADERS') do |s|
Index: file.c
===================================================================
--- file.c	(revision 17351)
+++ file.c	(working copy)
@@ -20,7 +20,6 @@
 #include <sys/cygwin.h>
 #endif
 
-#define OpenFile rb_io_t
 #include "ruby.h"
 #include "rubyio.h"
 #include "rubysig.h"
@@ -2329,18 +2328,6 @@ rb_file_s_umask(argc, argv)
 # endif
 #endif
 
-#if defined _WIN32 || defined __CYGWIN__
-#define USE_NTFS 1
-#else
-#define USE_NTFS 0
-#endif
-
-#if USE_NTFS
-#define istrailinggabage(x) ((x) == '.' || (x) == ' ')
-#else
-#define istrailinggabage(x) 0
-#endif
-
 #ifdef DOSISH_DRIVE_LETTER
 static inline int
 has_drive_letter(buf)
@@ -2452,9 +2439,8 @@ rb_path_last_separator(path)
     return last;
 }
 
-#define chompdirsep rb_path_end
 char *
-rb_path_end(path)
+chompdirsep(path)
     const char *path;
 {
     while (*path) {
@@ -2469,35 +2455,20 @@ rb_path_end(path)
     }
     return (char *)path;
 }
-
-#if USE_NTFS
-static char *
-ntfs_tail(const char *path)
+ 
+char *
+rb_path_end(path)
+    const char *path;
 {
-    while (*path && *path != ':') {
-	if (istrailinggabage(*path)) {
-	    const char *last = path++;
-	    while (istrailinggabage(*path)) path++;
-	    if (!*path || *path == ':') return (char *)last;
-	}
-	else if (isdirsep(*path)) {
-	    const char *last = path++;
-	    while (isdirsep(*path)) path++;
-	    if (!*path) return (char *)last;
-	    if (*path == ':') path++;
-	}
-	else {
-	    path = CharNext(path);
-	}
-    }
-    return (char *)path;
+    if (isdirsep(*path)) path++;
+    return chompdirsep(path);
 }
-#endif
 
 #if USE_NTFS
 static char *
 ntfs_tail(const char *path)
 {
+    while (*path == '.') path++;
     while (*path && *path != ':') {
 	if (istrailinggabage(*path)) {
 	    const char *last = path++;
@@ -2527,10 +2498,6 @@ ntfs_tail(const char *path)
 	p = buf + bdiff;\
 	pend = buf + buflen;\
     }\
-    rb_str_resize(result, buflen);\
-    buf = RSTRING(result)->ptr;\
-    p = buf + bdiff;\
-    pend = buf + buflen;\
 } while (0)
 
 #define BUFINIT() (\
@@ -2769,28 +2736,23 @@ file_expand_path(fname, dname, result)
 
 #if USE_NTFS
     *p = '\0';
-    if (!strpbrk(b = buf, "*?")) {
+    if ((s = strrdirsep(b = buf)) != 0 && !strpbrk(s, "*?")) {
 	size_t len;
 	WIN32_FIND_DATA wfd;
 #ifdef __CYGWIN__
-	int lnk_added = 0;
+	int lnk_added = 0, is_symlink = 0;
 	struct stat st;
-	char w32buf[MAXPATHLEN], sep = 0;
-	p = 0;
+	char w32buf[MAXPATHLEN];
+	p = (char *)s;
 	if (lstat(buf, &st) == 0 && S_ISLNK(st.st_mode)) {
-	    p = strrdirsep(buf);
-	    if (!p) p = skipprefix(buf);
-	    if (p) {
-		sep = *p;
-		*p = '\0';
-	    }
+	    is_symlink = 1;
+	    *p = '\0';
 	}
-	if (cygwin_conv_to_win32_path(buf, w32buf) == 0) {
+	if (cygwin_conv_to_win32_path((*buf ? buf : "/"), w32buf) == 0) {
 	    b = w32buf;
 	}
-	if (p) *p = sep;
-	else p = buf;
-	if (b == w32buf) {
+	if (is_symlink && b == w32buf) {
+	    *p = '\\';
 	    strlcat(w32buf, p, sizeof(w32buf));
 	    len = strlen(p);
 	    if (len > 4 && strcasecmp(p + len - 4, ".lnk") != 0) {
@@ -2798,24 +2760,30 @@ file_expand_path(fname, dname, result)
 		strlcat(w32buf, ".lnk", sizeof(w32buf));
 	    }
 	}
+	*p = '/';
 #endif
 	HANDLE h = FindFirstFile(b, &wfd);
 	if (h != INVALID_HANDLE_VALUE) {
 	    FindClose(h);
-	    p = strrdirsep(buf);
 	    len = strlen(wfd.cFileName);
 #ifdef __CYGWIN__
 	    if (lnk_added && len > 4 &&
 		strcasecmp(wfd.cFileName + len - 4, ".lnk") == 0) {
-		len -= 4;
+		wfd.cFileName[len -= 4] = '\0';
 	    }
+#else
+	    p = (char *)s;
 #endif
-	    if (!p) p = buf;
-	    buflen = ++p - buf + len;
-	    rb_str_resize(result, buflen);
+	    ++p;
+	    BUFCHECK(bdiff + len >= buflen);
 	    memcpy(p, wfd.cFileName, len + 1);
 	    p += len;
 	}
+#ifdef __CYGWIN__
+	else {
+	    p += strlen(p);
+	}
+#endif
     }
 #endif
 
@@ -3051,7 +3019,7 @@ rb_file_s_extname(klass, fname)
     if (!p)
 	p = name;
     else
-	p++;
+	name = ++p;
 
     e = 0;
     while (*p) {
@@ -3081,7 +3049,7 @@ rb_file_s_extname(klass, fname)
 	    break;
 	p = CharNext(p);
     }
-    if (!e || e+1 == p)	/* no dot, or the only dot is first or end? */
+    if (!e || e == name || e+1 == p)	/* no dot, or the only dot is first or end? */
 	return rb_str_new(0, 0);
     extname = rb_str_new(e, p - e);	/* keep the dot, too! */
     OBJ_INFECT(extname, fname);

それでは。
-- 
U.Nakamura <usa@garbagecollect.jp>


In This Thread