builtin duration: fill note length from context (#37)
This commit is contained in:
parent
fc95405a06
commit
0b14f0c563
@ -928,9 +928,7 @@ static Result<Value> builtin_duration(Interpreter &interpreter, std::vector<Valu
|
||||
for (auto &arg : args) {
|
||||
Try(traverse(interpreter, std::move(arg), [&](Chord &c) {
|
||||
for (Note ¬e : c.notes) {
|
||||
if (note.length) {
|
||||
total += *note.length;
|
||||
}
|
||||
total += note.length ? *note.length : interpreter.current_context->length;
|
||||
}
|
||||
}));
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user