In the section on Clone the description for function _guaranteelength is as below:
Clone can also be useful in constructing instances of a type within a generic context. Here's an example from the previous section except using Clone instead of Default:
But this function differs from the example in previous section in the method signature too as this takes an additional param fill_with. The signature of the function in section Default is as below:
Given this difference, I think the description for function _guranteelength in section Clone can be updated, as it differs from the previous example by taking an additional param. One way I can think of is:
Clone can also be useful in constructing instances of a type within a generic context. Here's the modified example from the previous section which makes use of Clone instead of Default:
P.S: Thank you for your excellent guides which provide a lucid explanation of many of the Rust concepts.
In the section on Clone the description for function _guaranteelength is as below:
Given this difference, I think the description for function _guranteelength in section Clone can be updated, as it differs from the previous example by taking an additional param. One way I can think of is:
P.S: Thank you for your excellent guides which provide a lucid explanation of many of the Rust concepts.