fix detection of eof reaching when using camlp4