Uh oh!
There was an error while loading. Please reload this page.
Mention spec and indented blocks in doctest docs - #51158
Conversation
This commit adds a new section to the Documentation Test docs, which briefly mentions indented code blocks, and links to the CommonMark specification for both. I’m not sure about saying "fenced code blocks the more popular choice in the Rust community” because it seems like I’m speaking for everyone, but I can’t think of a better way to phrase it!
rust-highfive
commented
May 29, 2018
(rust_highfive has picked a reviewer for you, use r? to override) |
QuietMisdreavus
commented
May 29, 2018
Thanks for writing this out! I can see how this can be a hidden gotcha - it got a few people when we switched to a CommonMark-compliant Markdown parser, since our previous one didn't create indented code blocks as readily as the new one did.
In situations like this I usually go for "considered more idiomatic" since it's partially about making our examples a certain way so people will copy them. It's another way to say "more popular" for this specific case, since the style's been around long enough to have gained a lot of traction! |
ogham
commented
May 29, 2018
That’s a good way of putting it. I’ve updated the PR |
steveklabnik
left a comment
There was a problem hiding this comment.
This is wonderful, thank you so much!
steveklabnik
commented
May 29, 2018
@bors: r+ rollup |
bors
commented
May 29, 2018
📌 Commit 8f8a7b9 has been approved by |
bors
commented
May 30, 2018
🔒 Merge conflict |
Mention spec and indented blocks in doctest docs Fixesrust-lang#49717. This commit adds a new section to the Documentation Test docs, which briefly mentions indented code blocks, and links to the CommonMark specification for both. I’m not sure about saying "fenced code blocks the more popular choice in the Rust community” because it seems like I’m speaking for everyone, but I can’t think of a better way to phrase it!
Rollup of 12 pull requests Successful merges: - #51050 (std::fs::DirEntry.metadata(): use fstatat instead of lstat when possible) - #51123 (Update build instructions) - #51127 (Add doc link from discriminant struct to function.) - #51146 (typeck: Do not pass the field check on field error) - #51147 (Stabilize SliceIndex trait.) - #51151 (Move slice::exact_chunks directly above exact_chunks_mut for more con…) - #51152 (Replace `if` with `if and only if` in the definition dox of `Sync`) - #51153 (Link panic and compile_error docs) - #51158 (Mention spec and indented blocks in doctest docs) - #51186 (Remove two redundant .nll.stderr files) - #51203 (Two minor `obligation_forest` tweaks.) - #51213 (fs: copy: Use File::set_permissions instead of fs::set_permissions) Failed merges:
emilyalbini
commented
Jun 4, 2018
@steveklabnik this probably needs to be r+ed again. |
emilyalbini
commented
Jun 4, 2018
Uh, nevermind. @ogham you need to rebase this PR on top of the latest master. |
TimNN
commented
Jun 12, 2018
@ogham, It looks like your PR needs a rebase, do you think you'll have the time to do that? |
emilyalbini
commented
Jun 20, 2018
@bors retry |
Mention spec and indented blocks in doctest docs Fixesrust-lang#49717. This commit adds a new section to the Documentation Test docs, which briefly mentions indented code blocks, and links to the CommonMark specification for both. I’m not sure about saying "fenced code blocks the more popular choice in the Rust community” because it seems like I’m speaking for everyone, but I can’t think of a better way to phrase it!
Rollup of 6 pull requests Successful merges: - #51158 (Mention spec and indented blocks in doctest docs) - #51629 (Do not consume semicolon twice while parsing local statement) - #51637 (Update zx_cprng_draw_new on Fuchsia) - #51664 (make more libsyntax methods public) - #51666 (Disable probestack when GCOV profiling is being used) - #51703 (Recognize the extra "LLVM tools versions" argument to build-manifest.) Failed merges: r? @ghost
Fixes#49717.
This commit adds a new section to the Documentation Test docs, which briefly mentions indented code blocks, and links to the CommonMark specification for both.
I’m not sure about saying "fenced code blocks the more popular choice in the Rust community” because it seems like I’m speaking for everyone, but I can’t think of a better way to phrase it!