Commit Graph
21 Commits
Author SHA1 Message Date
Jonathan Kelley 67af2d89dd Autofmt nested rsx using syn::Visitor (#2279)
* Nested macros using visitor pattern
2024-04-08 22:15:52 -07:00
Jonathan Kelley be99e29e5f Fixes to autofmt, make it more aggressive (#2230)
* fix: fmt unterminated if, be more aggressive with line splits

* Fix: Handle long exprs in for/if statements
2024-04-03 15:27:36 -07:00
Jonathan Kelley d8942a255b Fix #2104: fmt incorrectly using 1-indexing for columns (#2106)
* Fix #2104: fmt incorrectly using 1-indexing for columns

* Clippy...
2024-03-18 18:23:45 -07:00
Alex Parrill 52fb080193 Use indentation settings in dx fmt and vscode extension
Adds the ability to specify an indent string to public autofmt methods - either
a sequence of spaces or a tab character.

Get the indentation style and size from rustfmt for dx fmt, or from the editor
settings for the vscode extension.

Closes #1595
2023-11-01 17:24:18 -04:00
Evan Almloff d9e0b9a918 fix autoformatting raw strings 2023-06-02 12:03:56 -05:00
Jonathan Kelley 4e4e101eee fix: dont choke on emojji n exprs 2023-01-17 16:24:29 -08:00
Jonathan Kelley b81eca0433 fix: short expr lists should not eat the final exprs 2023-01-16 17:25:55 -08:00
Jonathan Kelley b6e4db1f2f fix: immediate exprs 2023-01-16 16:36:50 -08:00
Jonathan Kelley 3945928c59 fix: adjust padding on autofmt 2023-01-13 17:16:06 -08:00
Jonathan Kelley ac6035cb2a feat: parse entire file instead of hunting for verbtain 2023-01-13 16:46:34 -08:00
Jonathan Kelley 6cd87796f2 feat: allow ifchains and for loops 2023-01-13 10:51:12 -08:00
Jonathan Kelley 293ef9c690 fix: only flow exprs with indent in mind 2023-01-12 17:02:41 -08:00
Jonathan Kelley 983789e4c5 handle weird trailing whitespace in autofmt 2023-01-12 16:55:13 -08:00
Jonathan Kelley cc8b910cf3 fix emoji support in autofmt 2023-01-12 16:29:31 -08:00
Jonathan Kelley 74421d47fd fix comments being eaten in autofmt 2023-01-07 14:09:32 -08:00
Jonathan Kelley 181a51a63b wip: add whitespace parsing to rsx 2022-09-30 10:51:53 -07:00
Jonathan Kelley 5313fc0cc6 fix: trailing commas with key 2022-09-28 17:06:11 -07:00
Jonathan Kelley a37458b9fa chore: fixes to autoformat to prevent double rendering of expr line 2022-09-28 16:47:10 -07:00
Jonathan Kelley 251aafa5fd fix: fmting 2022-07-05 18:42:00 -04:00
Jonathan Kelley 19e6e43358 fix: only apply comments if relevant 2022-07-05 17:59:33 -04:00
Jonathan Kelley fa9ebe17cc feat: fix autoformatting around one liners 2022-07-05 17:49:16 -04:00