@@ -1421,6 +1421,8 @@ fn abstract_interpret_ops<'gc>(
14211421 locals. set_any ( object_register as usize ) ;
14221422 }
14231423 Op :: GetSlot { index : slot_id } => {
1424+ let slot_id = slot_id as usize ;
1425+
14241426 let stack_value = stack. pop ( activation) ?;
14251427
14261428 // The value must have a vtable
@@ -1450,6 +1452,8 @@ fn abstract_interpret_ops<'gc>(
14501452 }
14511453 }
14521454 Op :: SetSlot { index : slot_id } => {
1455+ let slot_id = slot_id as usize ;
1456+
14531457 let set_value = stack. pop ( activation) ?;
14541458 let stack_value = stack. pop ( activation) ?;
14551459
@@ -1475,7 +1479,9 @@ fn abstract_interpret_ops<'gc>(
14751479
14761480 // Skip the coercion when possible
14771481 if set_value. matches_type ( resolved_value_class) {
1478- optimize_op_to ! ( Op :: SetSlotNoCoerce { index: slot_id } ) ;
1482+ optimize_op_to ! ( Op :: SetSlotNoCoerce {
1483+ index: slot_id as u32
1484+ } ) ;
14791485 }
14801486 }
14811487 Op :: GetPropertyStatic { multiname } => {
@@ -1576,9 +1582,13 @@ fn abstract_interpret_ops<'gc>(
15761582 vtable. set_slot_class ( activation. gc ( ) , slot_id, value_class) ;
15771583
15781584 if set_value. matches_type ( resolved_value_class) {
1579- optimize_op_to ! ( Op :: SetSlotNoCoerce { index: slot_id } ) ;
1585+ optimize_op_to ! ( Op :: SetSlotNoCoerce {
1586+ index: slot_id as u32
1587+ } ) ;
15801588 } else {
1581- optimize_op_to ! ( Op :: SetSlot { index: slot_id } ) ;
1589+ optimize_op_to ! ( Op :: SetSlot {
1590+ index: slot_id as u32
1591+ } ) ;
15821592 }
15831593 }
15841594 Some ( Property :: Virtual {
@@ -1589,7 +1599,7 @@ fn abstract_interpret_ops<'gc>(
15891599
15901600 let mut result_op = Op :: CallMethod {
15911601 num_args : 1 ,
1592- index : disp_id,
1602+ index : disp_id as u32 ,
15931603 push_return_value : false ,
15941604 } ;
15951605
@@ -1631,9 +1641,13 @@ fn abstract_interpret_ops<'gc>(
16311641 vtable. set_slot_class ( activation. gc ( ) , slot_id, value_class) ;
16321642
16331643 if set_value. matches_type ( resolved_value_class) {
1634- optimize_op_to ! ( Op :: SetSlotNoCoerce { index: slot_id } ) ;
1644+ optimize_op_to ! ( Op :: SetSlotNoCoerce {
1645+ index: slot_id as u32
1646+ } ) ;
16351647 } else {
1636- optimize_op_to ! ( Op :: SetSlot { index: slot_id } ) ;
1648+ optimize_op_to ! ( Op :: SetSlot {
1649+ index: slot_id as u32
1650+ } ) ;
16371651 }
16381652 }
16391653 Some ( Property :: Virtual {
@@ -1643,7 +1657,7 @@ fn abstract_interpret_ops<'gc>(
16431657
16441658 let mut result_op = Op :: CallMethod {
16451659 num_args : 1 ,
1646- index : disp_id,
1660+ index : disp_id as u32 ,
16471661 push_return_value : false ,
16481662 } ;
16491663
@@ -1740,7 +1754,7 @@ fn abstract_interpret_ops<'gc>(
17401754 Some ( Property :: Slot { slot_id } )
17411755 | Some ( Property :: ConstSlot { slot_id } ) => {
17421756 optimize_op_to ! ( Op :: ConstructSlot {
1743- index: slot_id,
1757+ index: slot_id as u32 ,
17441758 num_args
17451759 } ) ;
17461760
@@ -2235,7 +2249,12 @@ fn optimize_get_property<'gc>(
22352249
22362250 vtable. set_slot_class ( activation. gc ( ) , slot_id, value_class) ;
22372251
2238- return Ok ( Some ( ( Op :: GetSlot { index : slot_id } , resolved_value_class) ) ) ;
2252+ return Ok ( Some ( (
2253+ Op :: GetSlot {
2254+ index : slot_id as u32 ,
2255+ } ,
2256+ resolved_value_class,
2257+ ) ) ) ;
22392258 }
22402259 Some ( Property :: Virtual {
22412260 get : Some ( disp_id) , ..
@@ -2244,7 +2263,7 @@ fn optimize_get_property<'gc>(
22442263
22452264 let mut result_op = Op :: CallMethod {
22462265 num_args : 0 ,
2247- index : disp_id,
2266+ index : disp_id as u32 ,
22482267 push_return_value : true ,
22492268 } ;
22502269
@@ -2293,7 +2312,7 @@ fn optimize_call_property<'gc>(
22932312
22942313 let mut result_op = Op :: CallMethod {
22952314 num_args,
2296- index : disp_id,
2315+ index : disp_id as u32 ,
22972316 push_return_value,
22982317 } ;
22992318
0 commit comments