feat: generate descriptors for all unstable features
Most unstable features don't have their own chapter in the unstable book, so a rustc helper tool (`src/tools/unstable-book-gen`) generates shims to fill the gaps.
Run this tool to generate the full unstable-book source before parsing it.
Add command for only opening external docs and attempt to fix vscode-remote issue
opening URI in a remote env causes vscode to ask the OS to handle `vscode-remote` URIs as there is no handler registered for such a scheme. This attempts to instruct vscode to handle those.
This is untested, as I can't figure out how to open a debug session on WSL rn.
String literals diagnose
Continues the work from #15744 to add diagnosis errors to Str, ByteStr, and CStr literal kinds.
Also replaces `unescape_char` for `unescape_byte` to use the correct method for Byte literals.
make mir::ProjectionStore-impls pub-accessible
When using RA as a crate the `mir::Place` `projection` is accessible, however there is no way to translate the `ProjectionId` to a `&[PlaceElem]`, as the `ProjectionId::lookup` is private.
Personally, I would only need the `ProjectionId::lookup`-fn to be `pub`, but I don't see any reason why the others should be kept private.. am I missing something `@HKalbasi` ?
Relates to: https://github.com/rust-lang/rust-analyzer/pull/15575
fix: add diagnostics messages for chars and byte literal errors
This PR adds error messages for different invalid byte or character literals.
Fixes#15395
feat: vscode: Support opening local documentation if available
This PR implements the VS code support for opening local documentation (server side support was already implemented in #14662).
[local_docs.webm](https://github.com/rust-lang/rust-analyzer/assets/9659253/715b84dd-4f14-4ba0-a904-749b847eb3d5)
Displaying local instead of web docs can have many benefits:
- the web version may have different features enabled than locally selected
- the standard library may be a different version than is available online
- the user may not be online and therefore cannot access the web documentation
- the documentation may not be available online at all, for example because it is for a new feature in a library the user is currently developing
If the documentation is not available locally, the extension still falls back to the web version.
Closes#12867.
-----
If my implementation isn't really idiomatic TypeScript: Sorry, I'm not much of a TypeScript developer. I am open to feedback, however.