mirror of
https://github.com/oven-sh/bun
synced 2026-02-15 05:12:29 +00:00
stricter boolean check
This commit is contained in:
@@ -3388,7 +3388,7 @@ pub const Expr = struct {
|
||||
},
|
||||
// "!!!a" => "!a"
|
||||
.e_unary => |un| {
|
||||
if (un.op == Op.Code.un_not and isBoolean(un.value)) {
|
||||
if (un.op == Op.Code.un_not and knownPrimitive(un.value) == .boolean) {
|
||||
return un.value;
|
||||
}
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user