> Do you know if CM can detect whether I'm compiling with > MLton or with SML/NJ? Yes. MLton doesn't define any preprocessor symbols with CM, so the following should work. # if ( defined (SMLNJ_VERSION) ) (* SML/NJ stuff here *) # else (* MLton stuff here *) # endif