From: Bulat Ziganshin Date: 2002-10-30T20:24:04+09:00 Subject: Re: feature idea: custom literals Hello Peter, Wednesday, October 30, 2002, 2:14:34 PM, you wrote: >> it's a literal for complex numbers PH> Fine. But HOW is his suggestion supposed to achieve this? if you ask about user interface, it is just list of hooks such as: def imaginary_literal(str) if str =~ /(\d+)i/i return Complex.new( 0, $1.to_i) else raise end end add_literal(:imaginary_literal) if you ask about realization details, i absolutely don't know HOW :) -- Best regards, Bulat mailto:bulatz@integ.ru