     explicitStart: Bool = false,
     explicitEnd: Bool = false,
     version: (major: Int, minor: Int)? = nil,
-    sortKeys: Bool = false) throws -> String {
+    sortKeys: Bool = false) throws -> String
+{
     return try serialize(
         node: object.represented(),
         canonical: canonical,

    explicitEnd: Bool = false,
    version: (major: Int, minor: Int)? = nil,
    sortKeys: Bool = false) throws -> String
    where Objects: Sequence {
        func representable(from object: Any) throws -> NodeRepresentable {
            if let representable = object as? NodeRepresentable {
                return representable
            }
            throw YamlError.emitter(problem: "\(object) does not conform to NodeRepresentable!")
        }
        let nodes = try objects.map(representable(from:)).map { try $0.represented() }
        return try serialize(
            nodes: nodes,
            canonical: canonical,
            indent: indent,
            width: width,
            allowUnicode: allowUnicode,
            lineBreak: lineBreak,
            explicitStart: explicitStart,
            explicitEnd: explicitEnd,
            version: version,
            sortKeys: sortKeys)
}

/// Produce YAML String from object
///
/// - Parameters:
///   - object: Object
///   - canonical: output should be the "canonical" format as in the YAML specification.
///   - indent: the intendation increment.
///   - width: the preferred line width. @c -1 means unlimited.
///   - allowUnicode: unescaped non-ASCII characters are allowed if true.
///   - lineBreak: preferred line break.
///   - explicitStart: explicit document start `---`
///   - explicitEnd: explicit document end `...`
///   - version: YAML version directive
/// - Returns: YAML String
/// - Throws: `YamlError`
public func dump(
    object: Any?,
    canonical: Bool = false,

//

#if SWIFT_PACKAGE
import CYaml
#endif
import Foundation

/// Produce a YAML string from objects.
///
/// - parameter objects:       Sequence of Objects.
/// - parameter canonical:     Output should be the "canonical" format as in the YAML specification.
/// - parameter indent:        The intendation increment.
/// - parameter width:         The preferred line width. @c -1 means unlimited.
/// - parameter allowUnicode:  Unescaped non-ASCII characters are allowed if true.
/// - parameter lineBreak:     Preferred line break.
/// - parameter explicitStart: Explicit document start `---`.
/// - parameter explicitEnd:   Explicit document end `...`.
/// - parameter version:       YAML version directive.
///
/// - returns: YAML string.
///
/// - throws: `YamlError`.
public func dump<Objects>(
    objects: Objects,
    canonical: Bool = false,
