Fix stale comment in hasStructuralChildren

Agent-Logs-Url: https://github.com/mikefarah/yq/sessions/24db9a8f-601d-4ccf-ada7-129ed3226bb6

Co-authored-by: mikefarah <1151925+mikefarah@users.noreply.github.com>
This commit is contained in:
copilot-swe-agent[bot] 2026-04-11 02:42:34 +00:00 committed by GitHub
parent 8c1cb6a5f0
commit 3cba9952db
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -514,7 +514,7 @@ func (te *tomlEncoder) encodeSeparateMapping(w io.Writer, path []string, m *Cand
func (te *tomlEncoder) hasStructuralChildren(m *CandidateNode) bool {
for i := 0; i < len(m.Content); i += 2 {
v := m.Content[i+1]
// Only consider it structural if mapping has EncodeHintSeparateBlock or is non-empty
// Only consider it structural if mapping has EncodeHintSeparateBlock
if v.Kind == MappingNode && v.EncodeHint == EncodeHintSeparateBlock {
return true
}