2024-06-13 12:30:48 +02:00
|
|
|
#![warn(clippy::str_to_string)]
|
|
|
|
|
|
|
|
|
|
fn main() {
|
|
|
|
|
let hello = "hello world".to_owned();
|
2025-02-28 23:20:48 +01:00
|
|
|
//~^ str_to_string
|
|
|
|
|
|
2024-06-13 12:30:48 +02:00
|
|
|
let msg = &hello[..];
|
|
|
|
|
msg.to_owned();
|
2025-02-28 23:20:48 +01:00
|
|
|
//~^ str_to_string
|
2024-06-13 12:30:48 +02:00
|
|
|
}
|