Changed printExpr to print to an OutStream