Skip to content

Commit 2ec8d13

Browse files
committed
ZJIT: Fix StringIntern's return type
1 parent e464c55 commit 2ec8d13

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

zjit/src/hir.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1269,7 +1269,7 @@ impl Function {
12691269
Insn::IsNil { val } if !self.type_of(*val).could_be(types::NilClass) => Type::from_cbool(false),
12701270
Insn::IsNil { .. } => types::CBool,
12711271
Insn::StringCopy { .. } => types::StringExact,
1272-
Insn::StringIntern { .. } => types::StringExact,
1272+
Insn::StringIntern { .. } => types::Symbol,
12731273
Insn::StringConcat { .. } => types::StringExact,
12741274
Insn::NewArray { .. } => types::ArrayExact,
12751275
Insn::ArrayDup { .. } => types::ArrayExact,
@@ -4510,7 +4510,7 @@ mod tests {
45104510
v5:BasicObject = ObjToString v3
45114511
v7:String = AnyToString v3, str: v5
45124512
v9:StringExact = StringConcat v2, v7
4513-
v11:StringExact = StringIntern v9
4513+
v11:Symbol = StringIntern v9
45144514
Return v11
45154515
"#]]);
45164516
}

0 commit comments

Comments
 (0)