class Nokogiri::XML::Builder
def insert(node, &block)
##
def insert(node, &block) node = @parent.add_child(node) if block begin old_parent = @parent @parent = node @arity ||= block.arity if @arity <= 0 instance_eval(&block) else yield(self) end ensure @parent = old_parent end end NodeBuilder.new(node, self) end