Skip to content

Add support for non-space indention#720

Merged
max-sixty merged 3 commits intomitsuhiko:masterfrom
nicholassm:master
Feb 10, 2025
Merged

Add support for non-space indention#720
max-sixty merged 3 commits intomitsuhiko:masterfrom
nicholassm:master

Conversation

@nicholassm
Copy link
Contributor

@nicholassm nicholassm commented Feb 9, 2025

  • Adds support for non-space indention - even a "weird" mix of e.g. tabs and spaces.
  • Note, I had to add String field to the Visitor struct because the whitespace before
    the macro keyword is not included in the syn crate.
  • I only added a few new test cases with pure tabs or a combination of tabs and white spaces
    as most existing tests were also impacted by the change (and thus also tested the feature).
  • Added changelog entry.

- Adds support for non-space indention - even a "weird" mix of e.g. tabs and spaces.
- Note, I had to add `String` field to the `Visitor` struct becasue the whitespace before
  the macro keyword is not included in the syn crate.
- I only added a few new test cases with pure tabs or a combination of tabs and white spaces
  as most existing tests were also impacted by the change (and thus also tested the feature).
@nicholassm
Copy link
Contributor Author

Sorry, nuked the old PR somehow. This fixes the conflicts and adds a changelog entry.

@max-sixty max-sixty changed the title Fixes https://github.com/mitsuhiko/insta/issues/679. Add support for non-space indention Feb 10, 2025
@max-sixty max-sixty merged commit d56ad0f into mitsuhiko:master Feb 10, 2025
15 checks passed
@max-sixty
Copy link
Collaborator

Thank you @nicholassm !

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.

2 participants