def define(*args, &block)
      options = args.extract_options!

      name, anonymous = if args.first
        [args.shift, false]
      else
        self.anonymous_block_number += 1
        ["anonymous_block_#{anonymous_block_number}", true]
      end

      block_definitions[name].tap do |block_definition|
        block_definition.add_options options, &block
        block_definition.anonymous = anonymous
      end
    end
def define(*args, &block)
      options = args.extract_options!

      name, anonymous = if args.first
        [args.shift, false]
      else
        self.anonymous_block_number += 1
        ["anonymous_block_#{anonymous_block_number}", true]
      end

      block_definitions[name].tap do |block_definition|
        block_definition.add_options options, &block
        block_definition.anonymous = anonymous
      end
    end
Define a block, unless a block by the same name is already defined.
   <%= blocks.define :some_block_name, :parameter1 => "1", :parameter2 => "2" do |options| %>
     <%= options[:parameter1] %> and <%= options[:parameter2] %>
   <% end %>

 Options:
 [+name+]
   The name of the block being defined (either a string or a symbol)
 [+options+]
   The default options for the block definition. Any or all of these options may be overridden by
   whomever calls "blocks.render" on this block.
 [+block+]
   The block that is to be rendered when "blocks.render" is called for this block.