Skip to content
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

Run doctest fails if the path include generic types #4729

Open
2 of 3 tasks
garro95 opened this issue Mar 8, 2025 · 0 comments
Open
2 of 3 tasks

Run doctest fails if the path include generic types #4729

garro95 opened this issue Mar 8, 2025 · 0 comments
Labels

Comments

@garro95
Copy link

garro95 commented Mar 8, 2025

Thank you for the bug report

  • I am using the latest version of lsp-mode related packages.
  • I checked FAQ and Troubleshooting sections
  • You may also try reproduce the issue using clean environment using the following command: M-x lsp-start-plain

Bug description

This is related to emacs-rustic/rustic#92 and rust-lang/rust-analyzer#19319

The Run Doctest button does not work properly if the type where the doctest is, includes generic types.

This is probably due to the command not properly escaping the <, > characters.

The output is:

cargo test --doc --package priority-queue -- priority_queue::PriorityQueue<I,P,H>::push --show-output
/bin/bash: line 1: I,P,H: No such file or directory

Compilation exited abnormally with code 1 at Mon Mar  3 23:16:28, duration 0.04 s

Steps to reproduce

Run Doctest on a doc comment with examples including generic types in the path.

Expected behavior

The doctest is run.

Which Language Server did you use?

rust-analyzer

OS

Linux

Error callstack

Anything else?

No response

@garro95 garro95 added the bug label Mar 8, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant