Skip to content

Commit

Permalink
Update OSL Utils.js
Browse files Browse the repository at this point in the history
  • Loading branch information
Mistium authored Dec 7, 2024
1 parent 5d68b9f commit 6cfa218
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion Resources/OSL Utils.js
Original file line number Diff line number Diff line change
Expand Up @@ -557,7 +557,7 @@ class OSLUtils {
ast.push(this.evalToken(cur))
}

const types = ["opr", "cmp", "qst", "bit", "log"];
const types = ["opr", "cmp", "qst", "bit", "log", "ury"];
for (let type of types) {
for (let i = START ?? 2; i < ast.length; i++) {
const cur = ast[i];
Expand All @@ -570,6 +570,11 @@ class OSLUtils {
ast.splice(i, 2);
i -= 1;
continue;
} else if (type === "ury") {
cur.right = ast[i + 1];
ast.splice(i, 1);
i -= 1;
continue;
}
cur.left = ast[i - 1];
cur.right = ast[i + 1];
Expand Down

0 comments on commit 6cfa218

Please sign in to comment.