Re #142: merge between @caseypatrickdriscoll 's work and my own