i tried

begin
	eval( str )
rescue
	puts $!
end

but my program terminates if str contains erraneous expressions
why doesn t rescue catch say "parser errors"?

this is from the book:

eval( aString [, aBinding [ file [ line ] ] ]) -> anObject

i have no guess how to use this. what do the nested [] mean?

thanks for help, -Meinrad