Skip to content

Commit 4d1fc35

Browse files
committed
add ? as a unary op
1 parent b985174 commit 4d1fc35

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Resources/OSL Utils.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1452,7 +1452,7 @@ class OSLUtils {
14521452
else if (this.logic.indexOf(cur) !== -1) return { type: "log", num: tkn.log, data: cur, inferredType: "boolean" }
14531453
else if (this.bitwise.indexOf(cur) !== -1) return { type: "bit", num: tkn.bit, data: cur }
14541454
else if (cur.startsWith("...")) return { type: "spr", num: tkn.spr, data: this.evalToken(cur.substring(3)) }
1455-
else if (["!", "-", "~"].includes(start) && cur.length > 1) {
1455+
else if (["!", "-", "~", "?"].includes(start) && cur.length > 1) {
14561456
const obj = { type: "ury", num: tkn.ury, data: start, right: this.evalToken(cur.slice(1)) };
14571457
switch (start) {
14581458
case "!": obj.inferredType = "boolean"; break;

0 commit comments

Comments
 (0)