What parameters for inline block (<< - BLOCK, param1, param2) mean?
I am reading some source code https://github.com/plataformatec/devise and found that the line of code is:
class_eval <<-URL_HELPERS, __FILE__, __LINE__ + 1
What are the parameters
__LINE__ + 1
to block the ad (which changes with respect to the inline box without these options)?
As an alternative example showing how HEREDOCs work, I wrote in IRB the other day:
require 'nokogiri' doc = Nokogiri.XML(<<ENDXML,&:noblanks) ...gobs and gobs of pasted xml... ENDXML
Even crazier is this legal syntax for passing multiple HEREDOC lines at once:
p( <<END1, <<-END2, <<END3 ) This indented text is part of the first parameter, END1 END1 And this text is part of param2 whose ending sigil may be indented END2 and finally this text is part of the third parameter END3 #=> " This indented text is part of\n the first parameter, END1\n" #=> "And this text is part of param2\n whose ending sigil may be indented\n" #=> "and finally this text\nis part of\nthe third parameter\n"