174 Commits

Author SHA1 Message Date
A4-Tacks
48dbd84021
Fix removed feature doc_auto_cfg for smol_str lib 2025-11-11 15:19:56 +08:00
Lukas Wirth
c012ee9a48 lib: Bump editions to 2024 and remove legacy files 2025-11-09 13:40:51 +01:00
Lukas Wirth
4cea939285
Merge pull request #20988 from Veykril/push-rutmxykksupu
Merge `smol_str` into rust-analyzer
2025-11-08 11:59:46 +00:00
Lukas Wirth
64b00e77a2 Reformat 2025-11-08 12:50:55 +01:00
Lukas Wirth
ed2ae231e0
Merge pull request #20990 from Veykril/push-zzrzusnvwpzp
Merge `ungrammar` into rust-analyzer
2025-11-08 10:48:56 +00:00
Lukas Wirth
df009eef0b Reformat 2025-11-08 11:40:25 +01:00
Lukas Wirth
f12388c023 Reformat 2025-11-08 11:12:59 +01:00
Lukas Wirth
3c741d5f7c Update Cargo.toml and lockfile 2025-11-08 11:10:13 +01:00
Lukas Wirth
6f83ceeda6 Subtree text-size 2025-11-07 20:27:18 +01:00
Lukas Wirth
f48b2f65d3 Subtree ungrammar 2025-11-07 20:19:36 +01:00
Lukas Wirth
f46ac05406 Subtree smol_str 2025-11-07 20:01:13 +01:00
Lukas Wirth
529d3b935d
Merge pull request #20393 from rust-lang/veykril/push-urpzrkwpkmxw
Fix non-lsp compliant `Response` definition
2025-08-06 16:12:58 +00:00
Lukas Wirth
fc9a89dd19 Fix non-lsp compliant Response definition 2025-08-06 18:01:44 +02:00
Lukas Wirth
ae8b69f33a Report the incorrect payload when failing to deserialize lsp messages 2025-08-06 17:30:18 +02:00
Shashi Shankar
4541495037 examples: add minimal_lsp.rs and FIFO test script.
* `examples/minimal_lsp.rs` – compact LSP server showing definition,
  completion, hover, rustfmt-based formatting, and dummy diagnostics.
  Advertises UTF-8 offset encoding.

* `examples/manual_test.sh` – FIFO script that streams the canonical
  nine LSP packets so anyone can validate the server from two terminals.

No new runtime deps; `anyhow` stays under [dev-dependencies].
2025-07-17 11:04:14 +02:00
Lukas Wirth
23712aea06 cargo upgrade 2025-06-13 10:08:20 +02:00
Lukas Wirth
1e1571e1c8 fix: Fix new nightly lints 2025-03-31 13:27:54 +02:00
Lukas Wirth
500ea05aef chore: Bump dependencies 2025-03-23 08:46:10 +01:00
BenjaminBrienen
7535bb4661 cargo fmt 2025-03-15 21:32:01 +01:00
BenjaminBrienen
70fc7b98c6 edition = "2024" 2025-03-15 21:32:01 +01:00
BenjaminBrienen
e70a9c5b9e rust-version = "1.85" 2025-03-15 21:32:01 +01:00
Eric Huss
22fff683c4 Update stdarch 2025-03-06 11:11:55 -08:00
Havard Eidnes
f4842d5803 line-index: don't try to use neon on big-endian aarch64. 2025-02-04 15:22:49 +00:00
Laurențiu Nicola
788acba2dd Rephrase comment 2025-01-23 13:52:39 +02:00
Piotr Osiewicz
b57157ea94 lsp-server: Drop outgoing messages on background thread
Closes #18961
2025-01-18 17:47:27 +01:00
Lukas Wirth
5211972743 internal: Split serde derive feature into serde_derive usage
Ideally we'd not have any dependency pull in the derive feature for faster build times, once that is the case this change would have an actual effect.
See https://github.com/matklad/macro-dep-test/blob/master/README.md for context.
2024-12-20 11:55:02 +01:00
Johannes Altmanninger
d42a4e6c88 line-index method to allow clamping column to line length
Part of #18240
2024-10-15 12:14:45 +02:00
Lukas Wirth
71a43aff4e fix: Don't panic lsp writer thread on dropped receiver 2024-09-06 09:13:00 +02:00
mo8it
0b541ebbaa Use crossbeam-channel from the workspace 2024-08-09 23:48:03 +02:00
Laurențiu Nicola
b392eb4eb5 Fix and enable unsafe_op_in_unsafe_fn 2024-07-25 08:41:30 +03:00
Hamir Mahal
7c34eb3880
style: simplify string interpolation 2024-05-30 16:18:49 -07:00
Wilfred Hughes
84fdb72525 fix: Report all LSP protocol errors with invalid_data
Previously we did not use invalid_data for serde errors, making it
harder to understand errors when the client sends malformed data to
the server.
2024-05-08 16:08:00 -07:00
Lukas Wirth
76463eee48 Move lint definition generation into xtask/codegen 2024-03-04 17:14:14 +01:00
bors
2074cc28de Auto merge of #16722 - mo8it:allocations, r=Veykril
Avoid some allocations

I went on a small `.clone()` hunting tour :D
2024-03-04 09:17:23 +00:00
Lukas Wirth
83a1ad5bfe Give all threads names 2024-03-01 13:19:55 +01:00
mo8it
06a883e32f Take a reference instead of cloning 2024-02-29 16:05:26 +01:00
Michel Lind
fafb16b052
lsp-server: add license files
The `lsp-server` crate is currently published without license files, which is
needed when packaging in Linux distributions.

Symlink the files from the repository root so they are kept in sync.

Test showing the files get picked up by `cargo package`:
```
michel in rust-analyzer/lib/lsp-server on  add-lsp-server-license [+] is 📦 v0.7.6 via 🐍 v3.12.1 (.venv311) via 🦀 v1.76.0
⬢ [fedora:39] ❯ cargo package --allow-dirty --no-verify
    Updating crates.io index
   Packaging lsp-server v0.7.6 (/home/michel/src/github/rust-lang/rust-analyzer/lib/lsp-server)
    Updating crates.io index
    Packaged 12 files, 59.6KiB (16.3KiB compressed)

michel in rust-analyzer/lib/lsp-server on  add-lsp-server-license [+] is 📦 v0.7.6 via 🐍 v3.12.1 (.venv311) via 🦀 v1.76.0
⬢ [fedora:39] ❯ tar tf ../../target/package/lsp-server-0.7.6.crate | grep LICENSE
lsp-server-0.7.6/LICENSE-APACHE
lsp-server-0.7.6/LICENSE-MIT
```

Signed-off-by: Michel Lind <salimma@fedoraproject.org>
2024-02-15 18:01:36 -06:00
Tetsuharu Ohzeki
bffb8880d5 lsp-server: Fix warnings about clippy str_to_string rule 2024-02-10 01:00:40 +09:00
Tetsuharu Ohzeki
1e4171bc6e clippy: Enable non_canonical_partial_ord_impl rule 2024-02-09 22:42:16 +09:00
Lukas Wirth
9e8a0fae0c Lint debug prints and disallowed types with clippy 2024-02-01 17:57:27 +01:00
Young-Flash
db9fd370ee minor: correct typos 2024-01-30 21:43:43 +08:00
Lukas Wirth
8a5829cf28 Re-order mod declarations 2024-01-27 11:02:34 +01:00
Johann Hemmann
bef355168a non_minimal_cfg 2024-01-19 17:31:01 +01:00
Johann Hemmann
4087dcf1db Add comment about false positive clippy lint 2024-01-19 16:55:45 +01:00
Johann Hemmann
3041164301 Temporarily allow all lints which occur
They will be removed one by one
2024-01-19 12:52:12 +01:00
Johann Hemmann
28c7fa8dc6 Fix CI 2 2024-01-18 14:18:07 +01:00
Johann Hemmann
fad4fa163c cargo clippy --fix 2024-01-18 13:59:49 +01:00
roife
df538288e0 internal: add inline for move_mask in line-index 2024-01-12 20:27:54 +08:00
roife
7c3744e4db internal: Speedup line index calculation via NEON for aarch64 2024-01-12 15:58:56 +08:00
homersimpsons
0f69276e60
line-index: Update README.md with suggestions
Co-authored-by: Laurențiu Nicola <lnicola@users.noreply.github.com>
2024-01-07 15:38:40 +01:00