-
Notifications
You must be signed in to change notification settings - Fork 278
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
cmd/cue: correctly import comments after a field key
The YAML decoder attached an inline key comment to the label, rather than to the entire field, which caused the comment to be printed before the colon character and cause weird formatting. Then teach cue/format to print an inline comment on a field colon. Fixes #3214. Change-Id: I17e669bc6c129dde86478d604a28d07fc63f7b69 Signed-off-by: haoqixu <hq.xu0o0@gmail.com> Reviewed-on: https://review.gerrithub.io/c/cue-lang/cue/+/1196291 Reviewed-by: Daniel Martí <mvdan@mvdan.cc> Unity-Result: CUE porcuepine <cue.porcuepine@gmail.com> TryBot-Result: CUEcueckoo <cueckoo@cuelang.org>
- Loading branch information
Showing
3 changed files
with
14 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters