By conservative opinions, such a device is considered impossible.
However, given the facts that:
Some, especially preset style, M42 lenses have a body that is, on the rearmost few centimetres, no thicker (or hardly thicker than, with only a minimal flange) than the threaded end – you could shove that section of the lens body through the mount.
The same style of lens often has nothing protruding past the threaded end.
There are several millimetres of space between the mirrorbox and the mount flange, at least on some F-mount APS-C DSLRs.
Could an adapter providing a (probably interrupted/sectioned) thread and minimal flange sunk a few mm into the camera throat be made (similar to some C-mount to mirrorless adapters), even if it would be unsafe to use with the wrong combination of lens and camera?