I created a module that makes pike segfault, and have narrowed it down to the simplest module that will reproduce the crash (its attached). Just doing indices(Crash) will make pike (7.6.50) segfault.
Its just calling Module.some_program from a Module.some_function that causes the problem. If I change Crash.head_asplode() to call crash() instead of Crash.crash() then it stops segfaulting.
But if Module.some_program is a regular class instead of a program variable pointed to a class, it also stops crashing. Like if I take out the "program crash = Crash.blah" and just make an actual crash.pike, then it won't segfault.
Adam