From 706faa10aa63fd6d0972d76fbd6c40a976a38766 Mon Sep 17 00:00:00 2001 From: r00ster Date: Sun, 5 Dec 2021 14:43:43 +0100 Subject: [PATCH] Update doc about code block edition attributes --- src/doc/rustdoc/src/documentation-tests.md | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/doc/rustdoc/src/documentation-tests.md b/src/doc/rustdoc/src/documentation-tests.md index 6be53fb4cfe..aea55d4f4b6 100644 --- a/src/doc/rustdoc/src/documentation-tests.md +++ b/src/doc/rustdoc/src/documentation-tests.md @@ -359,9 +359,8 @@ are added. # fn foo() {} ``` -`edition2018` tells `rustdoc` that the code sample should be compiled using -the 2018 edition of Rust. Similarly, you can specify `edition2015` to compile -the code with the 2015 edition. +`edition2015`, `edition2018` and `edition2021` tell `rustdoc` +that the code sample should be compiled using the respective edition of Rust. ```rust /// Only runs on the 2018 edition.