about summary refs log tree commit diff
path: root/library/std/src/sys/unix/stack_overflow.rs
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2020-12-25 11:16:53 +0000
committerbors <bors@rust-lang.org>2020-12-25 11:16:53 +0000
commitab107788547c285aaaa7dced6091663a6e0eea82 (patch)
tree357b6f3d1184fd648d2cdafabca2e7dea9efa022 /library/std/src/sys/unix/stack_overflow.rs
parent198ec340f6637a4a8cd3c0401f0dfc9d734838cc (diff)
parentdb1451c7ad08e77a17c59f6755f234ea507ead92 (diff)
downloadrust-ab107788547c285aaaa7dced6091663a6e0eea82.tar.gz
rust-ab107788547c285aaaa7dced6091663a6e0eea82.zip
Auto merge of #80226 - ThePuzzlemaker:issue-80004-fix, r=jyn514,petrochenkov
Highlight edition-specific keywords correctly in code blocks, accounting for code block edition modifiers

Previously, edition-specific keywords (such as `async` and `await`) were not highlighted in code blocks, regardless of what edition was set. With this PR, this issue is fixed.

Now, the following behavior happens:
- When a code block is explicitly set to edition X, keywords from edition X are highlighted
- When a code block is explicitly set to a version that does not contain those keywords from edition X (e.g. edition Y), keywords from edition X are **not** highlighted
- When a code block has no explicit edition, keywords from the edition passed via `--edition` to rustdoc are highlighted

For example, a project set with `edition = "2015"` in its `Cargo.toml` would not highlight `async`/`await` unless the code block was set to `edition2018`. Additionally, a project set with `edition = "2018"` in its `Cargo.toml` *would* highlight `async`/`await` unless the code block was set to a version that did not contain those keywords (e.g. `edition2015`).

This PR fixes #80004.

r? `@jyn514`
Diffstat (limited to 'library/std/src/sys/unix/stack_overflow.rs')
0 files changed, 0 insertions, 0 deletions