    # File lib/compass/configuration/helpers.rb, line 31
          def configuration_for(config, filename = nil, defaults = nil)
            if config.nil?
              nil
            elsif config.is_a?(Compass::Configuration::Data)
              config
            elsif config.respond_to?(:read)
              filename ||= config.to_s if config.is_a?(Pathname)
              Compass::Configuration::FileData.new_from_string(config.read, filename, defaults)
            elsif config.is_a?(Hash)
              Compass::Configuration::Data.new(filename, config)
            elsif config.is_a?(String)
              Compass::Configuration::FileData.new_from_file(config, defaults)
            elsif config.is_a?(Symbol)
              Compass::AppIntegration.lookup(config).configuration
            else
              raise "I don't know what to do with: #{config.inspect}"
            end
          end