New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Parse rust path in short doc links #9686
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Btw does rustdoc disallows spaces between brackets and backticks like this:
[ `foo` ]
?
src/main/kotlin/org/rust/lang/doc/psi/RsDocCommentElementType.kt
Outdated
Show resolved
Hide resolved
c2e5b6b
to
236d7df
Compare
Spaces are allowed, fixed |
And what about tabs, are they allowed? :D |
236d7df
to
0f90233
Compare
Looks like yes, fixed |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
bors r+
9686: Parse rust path in short doc links r=vlad20012 a=dima74 Continuation of #7353 Now paths in short links are parsed as `RsPath`, and thus resolve and completion works for them. Note that short links can be either a path or a label, depending on the existence of the corresponding link definition for the label ```rust /// [bar1] - direct link /// [bar2] - markdown label reference /// /// [bar2]: bar3 fn foo() {} ``` This together with #9688 will fix #6905 changelog: Support short [intra-doc links](https://doc.rust-lang.org/rustdoc/write-documentation/linking-to-items-by-name.html) (in format `[link]`) 9729: Enable `function-like` and `derive` proc macro expansion by default r=vlad20012 a=vlad20012 If you came to this PR because your issue just has been closed, note the plugin including PR will be released only in early December. If you can't wait to try it now, you can use the nightly IntelliJ Rust plugin channel (see [instructions](https://plugins.jetbrains.com/plugin/8182-rust/docs/rust-quick-start.html#install-nightly)). Derive macros support: Fixes #4629 Fixes #5468 Fixes #5478 Fixes #5728 Fixes #5954 Fixes #6036 Fixes #6489 Fixes #6880 Fixes #7158 Fixes #7848 Fixes #8193 Fixes #8415 Fixes #8581 Fixes #8610 Fixes #8847 Fixes #8856 Fixes #9133 Fixes #9216 Fixes #9226 Fixes #9682 Fixes #7707 Fixes #7365 Fixes #6482 Function-like macros support: Fixes #4707 Fixes #6367 Fixes #6983 Fixes #7090 Fixes #7242 Fixes #7608 Fixes #7699 Fixes #8049 Fixes #8785 Fixes #9266 changelog: Enable [`function-like`](https://doc.rust-lang.org/reference/procedural-macros.html#function-like-procedural-macros) and [`derive`](https://doc.rust-lang.org/reference/procedural-macros.html#derive-macros) proc macro expansion by default. Note that attribute procedural macro expansion is still disabled by default. If you want to try it, you can enable `org.rust.macros.proc.attr` [experimental feature](https://plugins.jetbrains.com/plugin/8182-rust/docs/#experimental-features). Co-authored-by: Dmitry Murzin <diralik@yandex.ru> Co-authored-by: vlad20012 <beskvlad@gmail.com>
Build failed (retrying...): |
9686: Parse rust path in short doc links r=vlad20012 a=dima74 Continuation of #7353 Now paths in short links are parsed as `RsPath`, and thus resolve and completion works for them. Note that short links can be either a path or a label, depending on the existence of the corresponding link definition for the label ```rust /// [bar1] - direct link /// [bar2] - markdown label reference /// /// [bar2]: bar3 fn foo() {} ``` This together with #9688 will fix #6905 changelog: Support short [intra-doc links](https://doc.rust-lang.org/rustdoc/write-documentation/linking-to-items-by-name.html) (in format `[link]`) 9741: INT: Don't offer `Un-elide lifetimes` intention when no input lifetimes r=mchernyavsky a=dima74 Fixes #9734 changelog: Don't offer `Un-elide lifetimes` intention when there is no input lifetimes Co-authored-by: Dmitry Murzin <diralik@yandex.ru>
Build failed (retrying...): |
bors r+ |
Already running a review |
Build succeeded: |
Continuation of #7353
Now paths in short links are parsed as
RsPath
, and thus resolve and completion works for them. Note that short links can be either a path or a label, depending on the existence of the corresponding link definition for the labelThis together with #9688 will fix #6905
changelog: Support short intra-doc links (in format
[link]
)