From e1e719e1a1916dee9365c390dcb640390433d078 Mon Sep 17 00:00:00 2001 From: Wilfred Hughes Date: Fri, 15 Mar 2024 10:51:41 -0700 Subject: Mention labelled blocks in `break` docs `break` doesn't require a loop, so note this in the docs. This is covered in the linked sections of the rust reference, but this page implied that `break` is only for loops. --- library/std/src/keyword_docs.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'library/std/src') diff --git a/library/std/src/keyword_docs.rs b/library/std/src/keyword_docs.rs index 873bfb6218b..8415f36eba2 100644 --- a/library/std/src/keyword_docs.rs +++ b/library/std/src/keyword_docs.rs @@ -48,7 +48,7 @@ mod as_keyword {} #[doc(keyword = "break")] // -/// Exit early from a loop. +/// Exit early from a loop or labelled block. /// /// When `break` is encountered, execution of the associated loop body is /// immediately terminated. -- cgit 1.4.1-3-g733a5