String.From_source
Conversion of a source of characters to a string.
module S : Interfaces.SOURCE with type item = char
make_with_size n s
Convert the stream s
of characters to a string where n
is an estimate of the length of the string.
The function works internally with a buffer. n
is used to guide the buffer allocation and the resizing of the buffer. The better the estimate, the fewer buffer allocations and resizes are necessary.