diff --git a/src/items.md b/src/items.md index 710a6778f..bbdabda16 100644 --- a/src/items.md +++ b/src/items.md @@ -365,9 +365,10 @@ fn my_err(s: &str) -> ! { ``` We call such functions "diverging" because they never return a value to the -caller. Every control path in a diverging function must end with a `panic!()` or -a call to another diverging function on every control path. The `!` annotation -does *not* denote a type. +caller. Every control path in a diverging function must end with a `panic!()`, +a loop expression without an associated break expression, or a call to another +diverging function on every control path. The `!` annotation does *not* denote +a type. It might be necessary to declare a diverging function because as mentioned previously, the typechecker checks that every control path in a function ends