Fix tactus marking in mininotation (#1144)

* more tactus tweaks
* format
This commit is contained in:
Alex McLean 2024-07-24 10:40:28 +01:00 committed by GitHub
parent f514cd85b1
commit 4c3457438d
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 18 additions and 5 deletions

View file

@ -14,7 +14,7 @@ const applyOptions = (parent, enter) => (pat, i) => {
const ast = parent.source_[i];
const options = ast.options_;
const ops = options?.ops;
const tactus_source = pat.__tactus_source;
if (ops) {
for (const op of ops) {
switch (op.type_) {
@ -39,6 +39,7 @@ const applyOptions = (parent, enter) => (pat, i) => {
} else {
pat = pat.euclid(enter(op.arguments_.pulse), enter(op.arguments_.step));
}
console.log(op.arguments_.step);
break;
}
case 'degradeBy': {
@ -69,7 +70,7 @@ const applyOptions = (parent, enter) => (pat, i) => {
}
}
}
pat.__tactus_source = pat.__tactus_source || tactus_source;
return pat;
};