Some preparatory changes for #41.