Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Nickel: formatting of single-line annotated let #768

Merged
merged 2 commits into from
Oct 17, 2024

Conversation

yannham
Copy link
Member

@yannham yannham commented Oct 16, 2024

Respect formatting of single-line annotated let in Nickel

Issue: #743

Description

Previously, we were formatting a let-binding followed by a single-line annotation and some content by always putting the = sign and the following content on a new line, indenting the content one level to the right.

This was mostly due to a limitation of Topiary around scopes. Today, this limitation has been lifted thanks to the introduction of measuring scopes. We make use of the latter to finally format such let-bindings (and bindings in general) as we originally wanted in #743.

Checklist

Checklist before merging:

  • CHANGELOG.md updated
  • README.md up-to-date

Previously, we were formatting a let-binding followed by a single-line
annotation and some content by always putting the `=` sign and the
following content on a new line, indenting the content one level to the
right.

This was mostly due to a limitation of Topiary around scopes. Today,
this limitation has been lifted thanks to the introduction of measuring
scopes. We make use of the latter to finally format such let-bindings
(and bindings in general) as we originally wanted (see
#743).
Copy link
Member

@Xophmeister Xophmeister left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 💯

@nbacquey nbacquey merged commit 7b1c316 into main Oct 17, 2024
9 checks passed
@nbacquey nbacquey deleted the fix/nickel-let-annotated-2 branch October 17, 2024 14:48
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.

3 participants