diff options
| author | Dylan DPC <dylan.dpc@gmail.com> | 2020-11-29 03:14:21 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2020-11-29 03:14:21 +0100 |
| commit | ca8a1b05c62d05d82fb6d5480dc9e4b4fdad1ce4 (patch) | |
| tree | 6383f8334a0365e06e6c08a8778d8ab313761c72 /compiler | |
| parent | d5d60364786f88bcea9d940ec056bb020c12aa5b (diff) | |
| parent | 482b3accdd2390b1cd0ffee850fe1c21468b6798 (diff) | |
| download | rust-ca8a1b05c62d05d82fb6d5480dc9e4b4fdad1ce4.tar.gz rust-ca8a1b05c62d05d82fb6d5480dc9e4b4fdad1ce4.zip | |
Rollup merge of #79464 - GuillaumeGomez:doc-keyword-ident, r=jyn514
Extend doc keyword feature by allowing any ident Part of #51315. As suggested by ``@danielhenrymantilla`` in [this comment](https://github.com/rust-lang/rust/issues/51315#issuecomment-733879934), this PR extends `#[doc(keyword = "...")]` to allow any ident to be used as keyword. The final goal is to allow (proc-)macro crates' owners to write documentation of the keywords they might introduce. r? ``@jyn514``
Diffstat (limited to 'compiler')
| -rw-r--r-- | compiler/rustc_span/src/symbol.rs | 5 |
1 files changed, 0 insertions, 5 deletions
diff --git a/compiler/rustc_span/src/symbol.rs b/compiler/rustc_span/src/symbol.rs index d5fccdeb189..523628b7058 100644 --- a/compiler/rustc_span/src/symbol.rs +++ b/compiler/rustc_span/src/symbol.rs @@ -1590,11 +1590,6 @@ impl Symbol { self == kw::Try } - /// Used for sanity checking rustdoc keyword sections. - pub fn is_doc_keyword(self) -> bool { - self <= kw::Union - } - /// A keyword or reserved identifier that can be used as a path segment. pub fn is_path_segment_keyword(self) -> bool { self == kw::Super |
