changed ErrorReporter to use stderr