Lukas Wirth
c310aee8d6
For toolchain binaries ue the full path found in $PATH
2024-03-05 10:17:09 +01:00
roife
ec5236f3a8
test: use 4 spaces for indetation in macro expansion
2024-02-27 20:53:07 +08:00
Lukas Wirth
7dd9f20ce3
Builtin derives are hygienic
2024-01-08 12:50:11 +01:00
Lukas Wirth
634d588fd7
Simplify
2023-12-06 14:36:39 +01:00
Lukas Wirth
d2cd30007c
Implicit format args support
2023-12-05 17:07:00 +01:00
Lukas Wirth
5b8e386bae
Improve macro descension API
2023-12-05 17:06:57 +01:00
Lukas Wirth
02a3a9438a
Some more minor cleanups
2023-12-02 17:04:13 +01:00
Lukas Wirth
30093a6d81
spans always come from real file
2023-11-28 10:55:39 +01:00
Lukas Wirth
890eb17b4e
Replace ID based TokenMap with proper relative text-ranges / spans
2023-11-28 10:55:39 +01:00
Laurențiu Nicola
cace36cade
Make Expand macro command title more explicit
2023-11-12 11:43:46 +02:00
Lukas Wirth
53b292478d
internal: Add offset param to token descending API
2023-08-16 10:07:18 +02:00
Lukas Wirth
c7ef6c25b7
internal: Replace Display impl for Name
2023-05-24 20:55:12 +02:00
hkalbasi
d9f4cbbe8f
Emit function bodies in expanding builtin derives
2023-05-03 14:14:47 +03:30
hkalbasi
c54cb88950
Add bounds for associated types in derive macro
2023-04-07 19:33:14 +03:30
Lukas Wirth
435d585d0c
Revert "Add bounds for fields in derive macro"
2023-04-07 11:01:17 +02:00
hkalbasi
0241b52dad
Add bounds for fields in derive macro
2023-04-07 02:21:46 +03:30
Ryo Yoshida
613e008593
Don't append "!" to non-bang macro name
2023-04-02 20:13:34 +09:00
Daniel Eades
ed128872eb
remove needless borrows
2023-01-02 14:52:32 +00:00
Jonas Schievink
bd7dfac5eb
Fix r-a spelling in some places
2022-08-01 13:47:09 +02:00
Amos Wenger
7e285e1ef5
Run cargo fmt
2022-07-20 15:06:15 +02:00
Amos Wenger
816f7fe12a
Run cargo fix --edition-idioms
2022-07-20 15:02:08 +02:00
Ryo Yoshida
36d2b43dfd
fix: improve whitespace insertion in pretty printer
2022-06-28 20:44:55 +09:00
Lukas Wirth
76ae5434fa
internal: Bump Dependencies
2022-06-10 17:30:02 +02:00
Lukas Wirth
86d1d9067e
fix: Insert whitespace into trait-impl completions when coming from macros
2022-05-24 22:56:33 +02:00
andylizi
e34ae760f0
add test for macro expand formatting
2022-05-24 12:45:58 +08:00
andylizi
ebf8b1a96e
ide: insert whitespaces surrounding _
in macro expansion
2022-05-24 07:54:43 +08:00
Lukas Wirth
3de9a42810
Disable rustfmt for expand_macro on wasm platforms
2022-04-17 14:00:19 +02:00
Lukas Wirth
895a16265c
Fix macro patterns not getting formatted properly
2022-04-17 13:46:00 +02:00
Lukas Wirth
e2f1a9a558
feat: Attempt to format expand_macro output with rustfmt if possible
2022-04-17 13:33:39 +02:00
Lukas Wirth
c37fe779c6
Add data queries for macros
2022-03-09 00:41:54 +01:00
Lukas Wirth
ab21cf2f4f
internal: Re-arrange ide_db modules
2022-03-06 19:04:04 +01:00
Lukas Wirth
2e124d15fb
fix: Fix expand_macro always expanding the first listed derive
2022-02-22 12:32:27 +01:00
Lukas Wirth
f13c98034b
Make replace_derive_with_manual_impl work again
2022-02-22 10:20:44 +01:00
Lukas Wirth
be3168dabe
Fix expand_macro
not working for derive attributes
2022-02-22 10:20:44 +01:00
Laurențiu Nicola
e14d9208f5
Move pretty-printing test out of assist
2022-01-06 16:38:25 +02:00
Jonas Platte
c90c88b083
Always put a space after impl in macro pretty-printing
...
… regardless of whether the next symbol is punctuation or not.
2022-01-06 11:33:08 +01:00
Lukas Wirth
749eeef3e7
fix: insert whitespaces into assoc items for assist when macro generated
2021-12-13 16:35:32 +01:00
Lukas Wirth
328419534d
Move ws insert rendering for macro expansion into ide_db
2021-12-13 15:55:13 +01:00
Jake Heinz
dca8f612d0
ide: fix expansion for 'as _'
2021-11-27 02:22:21 +00:00
Lukas Wirth
91bbc55eed
Check for derive attributes by item path, not derive
identifier
2021-11-17 20:46:57 +01:00
Anatol Ulrich
b42093915a
Update crates/ide/src/expand_macro.rs
...
Co-authored-by: Lukas Wirth <lukastw97@gmail.com>
2021-10-26 20:17:47 +02:00
Anatol Ulrich
e6913be47b
fix test
2021-10-26 20:15:25 +02:00
Anatol Ulrich
04f2eb0fba
wording
2021-10-26 20:10:09 +02:00
Anatol Ulrich
3f82989153
fix: make expand_macro
multi-token mapping aware
2021-10-26 20:09:14 +02:00
Mirko Rainer
eccfa1645b
Saw a FIXME comment and decided to fix it.
...
This renames `descend_into_macros` to `descend_into_macros_single` and `descend_into_macros_many` into `descend_into_macros`.
However, this does not touch a function in `SemanticsImpl` of same name.
2021-10-12 11:52:31 -04:00
nathan.whitaker
a3661b3900
Add whitespace b/w lifetime and mut in expansion
2021-10-01 15:29:26 -04:00
Lukas Wirth
538ac599d2
Add some more attribute ide tests
2021-09-14 03:57:29 +02:00
Lukas Wirth
0f3617f76f
fix: Fix multiple derives in one attribute not expanding all in expand_macro
2021-08-26 03:32:45 +02:00
Lukas Wirth
3f9f63c1bd
Improve expand_macro
2021-08-26 02:36:33 +02:00
Lukas Wirth
d99b81f839
Expand derive macros under cursor in Expand Macro Recursively
2021-08-24 16:33:52 +02:00