This is abuse: https://github.com/ajalt/fuckitpy
This is abuse: https://github.com/ajalt/fuckitpy
Heh.
[0] https://msdn.microsoft.com/en-us/library/aa266173(v=vs.60).a...
"On Error Resume Next specifies that when a run-time error occurs, control goes to the statement immediately following the statement where the error occurred where execution continues. Use this form rather than On Error GoTo when accessing objects."
https://gist.github.com/llllllllll/b1ac68a6b77535a64c0b13bfd...
(Python's LOAD_FAST bytecode does `fastlocals[i]`: how can we abuse the lack of bounds checking on this array access?)
(We've also discussed potential extensions this to approach "lift" C-extension code in bytestrings into interpreter objects. This would be useful to escalate existing interpreter attacks in environments that try to lock things down.)
t = (0, 1)
tuple_setitem(t, 0, 99)
print(t)
# (0, 1)
EDIT: Ah, it seems to work in 3.6.3