diff --git a/stdlib/src/utils/string_slice.mojo b/stdlib/src/utils/string_slice.mojo index 08e4e2180f..1a4674e95a 100644 --- a/stdlib/src/utils/string_slice.mojo +++ b/stdlib/src/utils/string_slice.mojo @@ -607,26 +607,6 @@ struct StringSlice[is_mutable: Bool, //, origin: Origin[is_mutable].type,]( """ return _atof(self) - fn __mul__(self, n: Int) -> String: - """Concatenates the string `n` times. - - Args: - n : The number of times to concatenate the string. - - Returns: - The string concatenated `n` times. - """ - - len_self = self.byte_length() - count = len_self * n + 1 - buf = String._buffer_type(capacity=count) - buf.size = count - b_ptr = buf.unsafe_ptr() - for i in range(n): - memcpy(b_ptr + len_self * i, self.unsafe_ptr(), len_self) - b_ptr[count - 1] = 0 - return String(buf^) - # ===------------------------------------------------------------------===# # Methods # ===------------------------------------------------------------------===#