Read repeated point spellings in a fixed order and end comments at a carriage return

Two spellings of one curve point, as v064 and v64, now give the same
result each time. A line comment ends at a lone carriage return, as in
sfizz. Header.Set's documentation says an include in the header's range
can override what it sets.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-12-02 00:46:19 +00:00
co-authored by Claude Sonnet 5.5
parent 37d2866fe9
commit 535856ba77
5 changed files with 45 additions and 4 deletions
+3 -1
View File
@@ -115,7 +115,9 @@ func onlySpace(nodes []*Node) bool {
// opcode that the header has keeps its place and the text around it, and takes
// the value as written, even if the value was a variable. A new opcode goes
// after the header's last, and after any comment on that opcode's line, laid
// out as that opcode is.
// out as that opcode is. Set doesn't read the files that #include reads in the
// header's range, so an opcode that one of them sets after this one takes
// effect instead.
func (h *Header) Set(name, value string) error {
value = strings.TrimSpace(value)
if err := checkOpcode(name, value); err != nil {