News for hackers. Stuff that matters.
Re:Make CPython segfault in 5 lines of code by westurner on Thursday December 19, 2019 @11:01AM (#21836037)
FWIW, this segfaults CPython in 2 lines:

  import ctypes
  ctypes.cast(1, ctypes.py_object)
Interestingly, this works:

  import ctypes, gc
  x = 22
  _id = id(x)
  del x
  gc.collect()
  y = ctypes.cast(_id, ctypes.py_object).value
  assert y == 22

There are no comments on this comment yet.