Skip to content

Commit

Permalink
Merge pull request #577 from tweag/571-nickel-formatting-regression
Browse files Browse the repository at this point in the history
Append scope to node before annotation
  • Loading branch information
ErinvanderVeen committed Jul 13, 2023
2 parents d4dbf3f + 243b62a commit 322ff5a
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 1 deletion.
2 changes: 1 addition & 1 deletion topiary/languages/nickel.scm
Expand Up @@ -274,7 +274,7 @@
; id | a -> a
(
(#scope_id! "annotations")
(_) @prepend_begin_scope
(_) @append_begin_scope
.
(annot) @append_end_scope
)
Expand Down
12 changes: 12 additions & 0 deletions topiary/tests/samples/expected/nickel.ncl
Expand Up @@ -10,6 +10,18 @@
id
| a -> a
},
#571
{
b =
{
kind = 'ReplicationController,
} | KubernetesConfig,
c =
{
kind = 'ReplicationController,
}
| KubernetesConfig
},

# Interpolated record operation chains (in
# a multi-line comment)
Expand Down
10 changes: 10 additions & 0 deletions topiary/tests/samples/input/nickel.ncl
Expand Up @@ -10,6 +10,16 @@
id |
a -> a
},
#571
{
b = {
kind = 'ReplicationController,
} | KubernetesConfig,
c = {
kind = 'ReplicationController,
}
| KubernetesConfig
},

# Interpolated record operation chains (in
# a multi-line comment)
Expand Down

0 comments on commit 322ff5a

Please sign in to comment.