Don't use the actual multiline doc comment syntax.

This commit is contained in:
Joseph Gerardot 2019-11-06 18:02:58 -05:00
parent e73884a1d4
commit 52020e4902
No known key found for this signature in database
GPG Key ID: 2078DC064C1359E4

View File

@ -59,13 +59,12 @@ impl Inventory {
}
}
/** Add a series of items to an inventory without giving duplicates. (n * m complexity)
*
* Error if inventory cannot contain the items (is full), returning the un-added items.
* This is a lazy inefficient implementation, as it iterates over the inventory more times
* than necessary (n^2) and with the proper structure wouldn't need to iterate at all, but because
* this should be fairly cold code, clarity has been favored over efficiency.
*/
/// Add a series of items to an inventory without giving duplicates. (n * m complexity)
///
/// Error if inventory cannot contain the items (is full), returning the un-added items.
/// This is a lazy inefficient implementation, as it iterates over the inventory more times
/// than necessary (n^2) and with the proper structure wouldn't need to iterate at all, but because
/// this should be fairly cold code, clarity has been favored over efficiency.
pub fn push_all_unique<I: Iterator<Item = Item>>(&mut self, mut items: I) -> Result<(), Error> {
let mut leftovers = Vec::new();
for item in &mut items {