 }
 #endif
 
-extension Int: NodeRepresentable {}
-extension Int16: NodeRepresentable {}
-extension Int32: NodeRepresentable {}
-extension Int64: NodeRepresentable {}
-extension Int8: NodeRepresentable {}
-extension UInt: NodeRepresentable {}
-extension UInt16: NodeRepresentable {}
-extension UInt32: NodeRepresentable {}
-extension UInt64: NodeRepresentable {}
-extension UInt8: NodeRepresentable {}
-
-private func represent(_ value: Any) throws -> Node {
-    if let string = value as? String {
-        return Node(string)
-    } else if let representable = value as? NodeRepresentable {
-        return try representable.represented()
-    }
-    throw YamlError.representer(problem: "Fail to represent \(value)")
-}
+extension Int: ScalarRepresentable {}
+extension Int16: ScalarRepresentable {}
+extension Int32: ScalarRepresentable {}
+extension Int64: ScalarRepresentable {}
+extension Int8: ScalarRepresentable {}
+extension UInt: ScalarRepresentable {}
+extension UInt16: ScalarRepresentable {}
+extension UInt32: ScalarRepresentable {}
+extension UInt64: ScalarRepresentable {}
+extension UInt8: ScalarRepresentable {}
 
 extension Optional: NodeRepresentable {
     public func represented() throws -> Node {

}

// MARK: - NodeRepresentable
public protocol NodeRepresentable {
    func represented() throws -> Node
}

        }
    }
}
