def selector_append(*selectors)
      if selectors.empty?
        raise ArgumentError.new("$selectors: At least one selector must be passed")
      end

      selectors.map {|sel| parse_selector(sel, :selectors)}.inject do |parent, child|
        child.members.each do |seq|
          sseq = seq.members.first
          unless sseq.is_a?(Sass::Selector::SimpleSequence)
            raise ArgumentError.new("Can't append \"#{seq}\" to \"#{parent}\"")
          end

          base = sseq.base
          case base
          when Sass::Selector::Universal
            raise ArgumentError.new("Can't append \"#{seq}\" to \"#{parent}\"")
          when Sass::Selector::Element
            unless base.namespace.nil?
              raise ArgumentError.new("Can't append \"#{seq}\" to \"#{parent}\"")
            end
            sseq.members[0] = Sass::Selector::Parent.new(base.name)
          else
            sseq.members.unshift Sass::Selector::Parent.new
          end
        end
        child.resolve_parent_refs(parent)
      end.to_sass_script
    end
def selector_append(*selectors)
      if selectors.empty?
        raise ArgumentError.new("$selectors: At least one selector must be passed")
      end

      selectors.map {|sel| parse_selector(sel, :selectors)}.inject do |parent, child|
        child.members.each do |seq|
          sseq = seq.members.first
          unless sseq.is_a?(Sass::Selector::SimpleSequence)
            raise ArgumentError.new("Can't append \"#{seq}\" to \"#{parent}\"")
          end

          base = sseq.base
          case base
          when Sass::Selector::Universal
            raise ArgumentError.new("Can't append \"#{seq}\" to \"#{parent}\"")
          when Sass::Selector::Element
            unless base.namespace.nil?
              raise ArgumentError.new("Can't append \"#{seq}\" to \"#{parent}\"")
            end
            sseq.members[0] = Sass::Selector::Parent.new(base.name)
          else
            sseq.members.unshift Sass::Selector::Parent.new
          end
        end
        child.resolve_parent_refs(parent)
      end.to_sass_script
    end
Return a new selector with all selectors in `$selectors` appended one
 another as though they had been nested in the stylesheet as `$selector1 {
 &$selector2 { ... } }`.

 @example
   selector-append(".foo", ".bar", ".baz") => .foo.bar.baz
   selector-append(".a .foo", ".b .bar") => "a .foo.b .bar"
   selector-append(".foo", "-suffix") => ".foo-suffix"

 @overload selector_append($selectors...)
   @param $selectors [[Sass::Script::Value::String, Sass::Script::Value::List]]
     The selectors to append. At least one selector must be passed. Each of
     these can be either a string, a list of strings, or a list of lists of
     strings as returned by `&`.
   @return [Sass::Script::Value::List]
     A list of lists of strings representing the result of appending
     `$selectors`. This is in the same format as a selector returned by
     `&`.
   @raise [ArgumentError] if a selector could not be appended.