Further changes to ASP solver, but segfaults at the moment