From: Minero Aoki Date: 2001-11-01T20:45:09+09:00 Subject: [ruby-talk:24074] Re: specifying the file and line In mail "[ruby-talk:24073] specifying the file and line" "Benoit Cerrina" wrote: > Hi, > is there a way to specify the file and line of a ruby program, > this is specially usefull for evals in an embedded interpreter. > In perl I do > # line 352 \"if_perl.xs\" Try this. eval <<-End, nil, 'somefilename.rb', 777 raise # to show lineno End module_eval/instance_eval has same feature. module_eval <<-End, 'somefilename.rb', 777 raise End instance_eval <<-End, 'somefilename.rb', 777 raise End Minero Aoki