遠藤と申します。 長い行でパースエラーすると SEGV することがあるようです。 $ ./ruby -e 'eval(%q(xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx = while true; [1, break]))' -e:1: [BUG] Segmentation fault ruby 1.9.0 (2007-12-29 revision 0) [i686-linux] -- control frame ---------- c:0004 p:---- s:0010 b:0010 l:000009 d:000009 CFUNC :eval c:0003 p:0009 s:0006 b:0006 l:000005 d:000005 TOP -e:1 c:0002 p:---- s:0004 b:0004 l:000003 d:000003 FINISH :inherited c:0001 p:0000 s:0002 b:0002 l:000001 d:000001 TOP <dummy toplevel>:17 --------------------------- DBG> : "-e:1:in `<main>'" -- backtrace of native function call (Use addr2line) -- 0x80eda35 0x810c3de 0x810c43b 0x80bdf50 0xffffe440 0x8106e11 0x8089645 0x808c8c3 0x809a50b 0x80efd69 0x8087da0 0x8087faf 0x80e21b6 0x80e2348 0x805ca2d 0x805ce95 0x80e3fae 0x80ec273 0x80e7bae 0x80eb474 0x80eb7ab 0x805a3f9 0x805e2e0 0x8057f51 0xb7d44ea8 0x8057e61 ------------------------------------------------------- アボートしました エラー行の省略表示 ("...line..." みたいなの) をする時に M17N がらみの 問題が起きているような気がします。既出だったらごめんなさい。 # M17N にはあまり興味がないので報告だけ。。。 Program received signal SIGSEGV, Segmentation fault. [Switching to Thread -1210410112 (LWP 20858)] rb_enc_get_index (obj=0) at encoding.c:397 397 switch (BUILTIN_TYPE(obj)) { (gdb) bt #0 rb_enc_get_index (obj=0) at encoding.c:397 #1 0x08106e11 in rb_enc_get (obj=0) at encoding.c:499 #2 0x08089645 in parser_yyerror (parser=0x81bd1a0, msg=<value optimized out>) at parse.y:4607 #3 0x0808c8c3 in ruby_yyparse (parser=0x81bd1a0) at parse.c:9380 #4 0x0809a50b in yycompile0 (arg=136040864, tracing=0) at parse.y:4681 #5 0x080efd69 in ruby_suppress_tracing (func=0x809a4a0 <yycompile0>, arg=136040864, always=2) at thread.c:2990 #6 0x08087da0 in yycompile (parser=0x81bd1a0, f=<value optimized out>, line=1) at parse.y:4712 #7 0x08087faf in rb_parser_compile_string (vparser=3081884080, f=0xb7b1d1cc "(eval)", s=3081884120, line=1) at parse.y:4770 #8 0x080e21b6 in rb_iseq_compile_with_option (src=3081884120, file=3081884100, line=3, opt=4) at iseq.c:420 #9 0x080e2348 in rb_iseq_compile (src=3081884120, file=3081884100, line=3) at iseq.c:450 #10 0x0805ca2d in eval (self=<value optimized out>, src=3081884120, scope=4, file=0x8120d37 "(eval)", line=1) at eval.c:1725 #11 0x0805ce95 in rb_f_eval (argc=1, argv=0xb7b48024, self=3082049100) at eval.c:1826 #12 0x080e3fae in call_cfunc (func=0x805cdc0 <rb_f_eval>, recv=3082049100, len=136041096, argc=0, argv=0xb7b48024) at vm_insnhelper.c:281 #13 0x080ec273 in vm_call_method (th=0x816e990, cfp=0xb7bc7f60, num=1, blockptr=0x1, flag=2145, id=2728, mn=0xb7b40fac, recv=3082049100, klass=3082049080) at vm_insnhelper.c:371 #14 0x080e7bae in vm_eval (th=0x816e990, initial=0) at insns.def:1050 #15 0x080eb474 in vm_eval_body (th=0x816e990) at vm.c:1148 #16 0x080eb7ab in rb_iseq_eval (iseqval=3081884240) at vm.c:1357 #17 0x0805a3f9 in ruby_exec_node (n=0xb7b1d2dc, file=0x81b4d11 "-e") at eval.c:229 #18 0x0805e2e0 in ruby_run_node (n=0xb7b1d2dc) at eval.c:259 #19 0x08057f51 in main (argc=3, argv=0xbfc66ef4, envp=0xbfc66f04) at main.c:39 -- Yusuke ENDOH <mame / tsg.ne.jp>