mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-23 07:14:28 +00:00
Enable smart punctuation
This commit is contained in:
parent
bb587b1a17
commit
a0f9d4beec
@ -52,11 +52,12 @@ pub(crate) fn opts() -> Options {
|
||||
| Options::ENABLE_FOOTNOTES
|
||||
| Options::ENABLE_STRIKETHROUGH
|
||||
| Options::ENABLE_TASKLISTS
|
||||
| Options::ENABLE_SMART_PUNCTUATION
|
||||
}
|
||||
|
||||
/// A subset of [`opts()`] used for rendering summaries.
|
||||
pub(crate) fn summary_opts() -> Options {
|
||||
Options::ENABLE_STRIKETHROUGH
|
||||
Options::ENABLE_STRIKETHROUGH | Options::ENABLE_SMART_PUNCTUATION
|
||||
}
|
||||
|
||||
/// When `to_string` is called, this struct will emit the HTML corresponding to
|
||||
|
@ -4,6 +4,6 @@ extern crate inner;
|
||||
|
||||
|
||||
// @has add_docs/struct.MyStruct.html
|
||||
// @has add_docs/struct.MyStruct.html "Doc comment from 'pub use', Doc comment from definition"
|
||||
// @has add_docs/struct.MyStruct.html "Doc comment from ‘pub use’, Doc comment from definition"
|
||||
/// Doc comment from 'pub use',
|
||||
pub use inner::MyStruct;
|
||||
|
13
src/test/rustdoc/smart-punct.rs
Normal file
13
src/test/rustdoc/smart-punct.rs
Normal file
@ -0,0 +1,13 @@
|
||||
#![crate_name = "foo"]
|
||||
|
||||
//! This is the "start" of the 'document'! How'd you know that "it's" the start?
|
||||
//!
|
||||
//! # Header with "smart punct'"
|
||||
//!
|
||||
//! [link with "smart punct'" -- yessiree!][]
|
||||
//!
|
||||
//! [link with "smart punct'" -- yessiree!]: https://www.rust-lang.org
|
||||
|
||||
// @has "foo/index.html" "//p" "This is the “start” of the ‘document’! How’d you know that “it’s” the start?"
|
||||
// @has "foo/index.html" "//h1" "Header with “smart punct’”"
|
||||
// @has "foo/index.html" '//a[@href="https://www.rust-lang.org"]' "link with “smart punct’” – yessiree!"
|
Loading…
Reference in New Issue
Block a user