Combine interpreter state variables into state record #est

This is mainly just to make handling of them easier and not so much
for hiding internal fields which are explicitly accessed when
necessary. It will also make it easier to add new fields when
necessary.
Make it work for loading files as well