Merging rvagg/Nan branch on latest master