diff --git a/exercises/bob/example.rs b/exercises/bob/example.rs index a6512f867..60505ccc6 100644 --- a/exercises/bob/example.rs +++ b/exercises/bob/example.rs @@ -1,4 +1,4 @@ -pub fn reply(message: &str) -> &str { +pub fn reply(message: &str) -> &'static str { if is_silence(message) { "Fine. Be that way!" } else if is_yelling(message) && is_question(message) { "Calm down, I know what I'm doing!" } else if is_yelling(message) { "Whoa, chill out!" } diff --git a/exercises/bob/src/lib.rs b/exercises/bob/src/lib.rs index d0417c9d1..cea08e1d6 100644 --- a/exercises/bob/src/lib.rs +++ b/exercises/bob/src/lib.rs @@ -1,3 +1,3 @@ -pub fn reply(message: &str) -> &str { - unimplemented!("have Bob reply to the incoming message: {}", message) -} +pub fn reply(message: &str) -> &'static str { + unimplemented!("have Bob reply to the incoming message: {}", message) +}