pub fn write_content_length<B: BufMut>(n: u64, buf: &mut B) {
    if n == 0 {
        buf.put_slice(b"\r\ncontent-length: 0\r\n");
        return;
    }

    let mut buffer = itoa::Buffer::new();

    buf.put_slice(b"\r\ncontent-length: ");
    buf.put_slice(buffer.format(n).as_bytes());
    buf.put_slice(b"\r\n");
}
/// Write out content length header.
///
/// Buffer must to contain enough space or be implicitly extendable.
Write out content length header.
Buffer must to contain enough space or be implicitly extendable.
Write out content length header . Buffer must to contain enough space or be implicitly extendable .
pub fn write_content_length<B: BufMut>(n: u64, buf: &mut B) {
    if n == 0 {
        buf.put_slice(b"\r\ncontent-length: 0\r\n");
        return;
    }
    let mut buffer = itoa::Buffer::new();
    buf.put_slice(b"\r\ncontent-length: ");
    buf.put_slice(buffer.format(n).as_bytes());
    buf.put_slice(b"\r\n");
}
pub fn write_content_length < B : BufMut > ( n : u64 , buf : & mut B ) { if n == 0 { buf . put_slice ( b" \r \n \r \n " ) ; return ; } let mut buffer = itoa :: Buffer :: new ( ) ; buf . put_slice ( b" \r \n " ) ; buf . put_slice ( buffer . format ( n ) . as_bytes ( ) ) ; buf . put_slice ( b" \r \n " ) ; }
Write out content length header.
Write out content length header .
n
u64
buf
&mut B
n
u64
buf
&mut B