about summary refs log tree commit diff
path: root/tests/rustdoc-ui/custom_code_classes_in_docs-warning.rs
diff options
context:
space:
mode:
authorGuillaume Gomez <guillaume1.gomez@gmail.com>2023-09-19 20:23:20 +0200
committerGitHub <noreply@github.com>2023-09-19 20:23:20 +0200
commit52a0d136f5c542846c7ccc17c12103a9d547a76a (patch)
treeae4dff55c4c84c2dd032d4d0ae5cfb4a6430f66b /tests/rustdoc-ui/custom_code_classes_in_docs-warning.rs
parent0060db74f9530c9239b256c45dff8815667343cc (diff)
parent295ec09b63b1c8352d4a75895eb5d8bd85975b16 (diff)
Rollup merge of #115947 - GuillaumeGomez:custom_code_classes_in_docs-warning, r=notriddle
Custom code classes in docs warning

Fixes https://github.com/rust-lang/rust/issues/115938.

This PR does two things:
 1. Unless the `custom_code_classes_in_docs` feature is enabled, it will use the old codeblock tag parser.
 2. If there is a codeblock tag that starts with a `.`, it will emit a behaviour change warning.

Hopefully this is the last missing part for this feature until stabilization.

Follow-up of https://github.com/rust-lang/rust/pull/110800.

r? `@notriddle`
Diffstat (limited to 'tests/rustdoc-ui/custom_code_classes_in_docs-warning.rs')
-rw-r--r--tests/rustdoc-ui/custom_code_classes_in_docs-warning.rs8
1 files changed, 3 insertions, 5 deletions
diff --git a/tests/rustdoc-ui/custom_code_classes_in_docs-warning.rs b/tests/rustdoc-ui/custom_code_classes_in_docs-warning.rs
index dd8759b7e37..5398d5833c7 100644
--- a/tests/rustdoc-ui/custom_code_classes_in_docs-warning.rs
+++ b/tests/rustdoc-ui/custom_code_classes_in_docs-warning.rs
@@ -57,25 +57,23 @@ pub fn foo8() {}
 /// ```{class=one=two}
 /// main;
 /// ```
-//~^^^ ERROR unexpected `=`
+//~^^^ ERROR unexpected `=` character
 pub fn foo9() {}
 
 /// ```{.one.two}
 /// main;
 /// ```
-//~^^^ ERROR unexpected `.` character
 pub fn foo10() {}
 
-/// ```{class=.one}
+/// ```{class=(one}
 /// main;
 /// ```
-//~^^^ ERROR unexpected `.` character after `=`
+//~^^^ ERROR unexpected `(` character after `=`
 pub fn foo11() {}
 
 /// ```{class=one.two}
 /// main;
 /// ```
-//~^^^ ERROR unexpected `.` character
 pub fn foo12() {}
 
 /// ```{(comment)}