 
 /// A type with a customized textual representation.
 ///
-/// This textual representation is used when objects are written to an
+/// This textual representation is used when values are written to an
 /// *output stream*, for example, by `print` and `println`.
 ///
 /// In order to generate a textual representation for an instance of any

/// protocols mentioned above.
@inline(never)
public func print<T, TargetStream : OutputStreamType>(
    object: T, inout target: TargetStream
) {
  if let streamableObject = object as? Streamable {
    streamableObject.writeTo(&target)
    return
  }

  if var printableObject = object as? Printable {
    printableObject.description.writeTo(&target)
    return
  }

  if let debugPrintableObject = object as? DebugPrintable {
    debugPrintableObject.debugDescription.writeTo(&target)
    return
  }

  _adHocPrint(object, &target)
}

/// Writes the textual representation of `object` and a newline character into
/// the stream `target`.
///
/// The textual representation is obtained from the `object` using its protocol
/// conformances, in the following order of preference: `Streamable`,
/// `Printable`, `DebugPrintable`.
///

/// See also: `debugPrintln(x, &target)`
@inline(never)
public func debugPrint<T, TargetStream : OutputStreamType>(
    value: T, inout target: TargetStream
) {
  if let debugPrintableObject = value as? DebugPrintable {
    debugPrintableObject.debugDescription.writeTo(&target)
    return
  }

  if var printableObject = value as? Printable {
    printableObject.description.writeTo(&target)
    return
  }

  if let streamableObject = value as? Streamable {
    streamableObject.writeTo(&target)
    return
  }

  _adHocPrint(value, &target)
}

/// Write to `target` the textual representation of `x` most suitable
