use curry2 to remove boilerplate
Merge pull request #284 from davidchambers/curry2

use curry2 to remove boilerplate
trim trailing whitespace
Merge pull request #285 from davidchambers/whitespace

trim trailing whitespace
more documentation regularization