]> git.lizzy.rs Git - rust.git/blob - tests/rustdoc/smart-punct.rs
Rollup merge of #106641 - chenyukang:yukang/fix-105761-segguest-this, r=estebank
[rust.git] / tests / rustdoc / smart-punct.rs
1 #![crate_name = "foo"]
2
3 //! This is the "start" of the 'document'! How'd you know that "it's" the start?
4 //!
5 //! # Header with "smart punct'"
6 //!
7 //! [link with "smart punct'" -- yessiree!][]
8 //!
9 //! [link with "smart punct'" -- yessiree!]: https://www.rust-lang.org
10 //!
11 //! # Code should not be smart-punct'd
12 //!
13 //! `this inline code -- it shouldn't have "smart punct"`
14 //!
15 //! ```
16 //! let x = "don't smart-punct me -- please!";
17 //! ```
18 //!
19 //! ```text
20 //! I say "don't smart-punct me -- please!"
21 //! ```
22
23 // @has "foo/index.html" "//p" "This is the “start” of the ‘document’! How’d you know that “it’s” the start?"
24 // @has "foo/index.html" "//h2" "Header with “smart punct’”"
25 // @has "foo/index.html" '//a[@href="https://www.rust-lang.org"]' "link with “smart punct’” – yessiree!"
26 // @has "foo/index.html" '//code' "this inline code -- it shouldn't have \"smart punct\""
27 // @has "foo/index.html" '//pre' "let x = \"don't smart-punct me -- please!\";"
28 // @has "foo/index.html" '//pre' "I say \"don't smart-punct me -- please!\""