oops. this implements #47 ;)