Minor cleanup and initial work for #58