move the outputfile open to after lexing, so a failed lexer run does not result in an empty file
move the outputfile open to after lexing, so a failed lexer run does not result in an empty file

darkfoxprime/foxCAT,darkfoxprime/foxCAT