From: Bob Hutchison Date: 2006-12-01T23:20:12+09:00 Subject: Re: Segmentation fault, proc, eval, long string [Reproduced] On 1-Dec-06, at 7:31 AM, Pit Capitain wrote: > Bob Hutchison schrieb: >> So I put some printf into the eval.c file and it turns out that >> rb_eval is called recursively 5301 times before seg faulting, >> while trying to handle a NODE_DASGN_CURR node. There are no other >> eval node types being evaluated when this begins, every node is a >> NODE_DASGN_CURR. >> There is nothing that is anywhere that deep in the script that I >> am evaluating. So it looks as though the proc object is corrupt?? >> So maybe this is reproducible?? Well, so it is. If I run this script: >> (...) >> It will fail on the one linux box, run on the other, and run on OS >> X. With a little binary search, the smallest N that causes the >> segfault is 3024 (3023 works). > > Bob, you can use parsetree to dump the AST of the generated proc. > I'm sure you'll see the deep nesting of the nodes. Okay, I'll do that. But a Segmentation Fault? Surely there's a more polite way to deal with the problem. Cheers, Bob > > Regards, > Pit > ---- Bob Hutchison -- blogs at Recursive Design Inc. -- Raconteur -- xampl for Ruby --