Just saw this intermittent error during compile in the OS X Particle Dev IDE. Using the latest version (1.0.15). Something you might want to look into in your .js code - I’ve attached the stack trace for you. (Is there a better place to post these things in the future, or a bug tracking system I can just enter into directly? - sorry if I’m not aware).
After closing the project folder, quitting Particle Dev, restarting the app, and re-compiling, the compile succeeded.