@@ -77,10 +77,10 @@ void doList(VirtualFrame frame, PList object, Object key, Object value,
77
77
}
78
78
79
79
@ InliningCutoff
80
- @ Specialization
81
- void doWithFrame (VirtualFrame frame , Object primary , Object index , Object value ,
80
+ @ Specialization ( replaces = "doList" )
81
+ void doWithFrame (Frame frame , Object primary , Object index , Object value ,
82
82
@ Cached GetClassNode getClassNode ,
83
- @ Cached ("create( SetItem) " ) LookupSpecialMethodSlotNode lookupSetitem ,
83
+ @ Cached (parameters = " SetItem" ) LookupSpecialMethodSlotNode lookupSetitem ,
84
84
@ Cached PRaiseNode raise ,
85
85
@ Cached CallTernaryMethodNode callSetitem ) {
86
86
Object setitem = lookupSetitem .execute (frame , getClassNode .execute (primary ), primary );
@@ -90,20 +90,6 @@ void doWithFrame(VirtualFrame frame, Object primary, Object index, Object value,
90
90
callSetitem .execute (frame , setitem , primary , index , value );
91
91
}
92
92
93
- @ InliningCutoff
94
- @ Specialization (replaces = {"doWithFrame" , "doList" })
95
- void doGeneric (Object primary , Object index , Object value ,
96
- @ Cached GetClassNode getClassNode ,
97
- @ Cached (parameters = "SetItem" ) LookupCallableSlotInMRONode lookupSetitem ,
98
- @ Cached PRaiseNode raise ,
99
- @ Cached CallTernaryMethodNode callSetitem ) {
100
- Object setitem = lookupSetitem .execute (getClassNode .execute (primary ));
101
- if (setitem == PNone .NO_VALUE ) {
102
- throw raise .raise (TypeError , ErrorMessages .P_OBJ_DOES_NOT_SUPPORT_ITEM_ASSIGMENT , primary );
103
- }
104
- callSetitem .execute (null , setitem , primary , index , value );
105
- }
106
-
107
93
public static PyObjectSetItem create () {
108
94
return PyObjectSetItemNodeGen .create ();
109
95
}
0 commit comments