Skip to content

fix: preserve comment placement in formatter#247

Merged
ivov merged 7 commits into
mainfrom
formatter-comment-placement
May 1, 2026
Merged

fix: preserve comment placement in formatter#247
ivov merged 7 commits into
mainfrom
formatter-comment-placement

Conversation

@ivov
Copy link
Copy Markdown
Owner

@ivov ivov commented May 1, 2026

Comments now stay attached to the element the user wrote them on, instead of being moved out of enclosing braces, merged onto adjacent lines, swapped past #[attr], or migrated to the next sibling.

fn f(
  a: int,
  // between params
  b: int,
) -> int {
  a + b
}

Includes refactoring the formatter into submodules for maintainability.

@ivov ivov changed the title fix: preserve comment placement across syntactic boundaries fix: preserve comment placement in formatter May 1, 2026
@ivov ivov merged commit d2b4ca2 into main May 1, 2026
11 checks passed
@ivov ivov mentioned this pull request May 1, 2026
@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented May 1, 2026

Released in lisette-v0.1.24

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant