+Start :: *World -> *StartType
+Start w
+# (args, w) = parseArgs w
+| args.help
+ # (out, w) = stdio w
+ # out = out <<< "\nUsage: " <<< args.program <<< " [opts] [FILENAME]\n"
+ <<< "\t--help Show this help\n"
+ <<< "\t--lex Lex only, is mutually exclusive with --parse\n"
+ <<< "\t--parse Lex & Parse only\n\n"
+ <<< "\tFILENAME File to parse, when unspecified stdin is parsed\n"
+ # (_, w) = fclose out w
+ = (Left "", Left "", w)
+# (stdin, w) = stdio w
+# (contents, stdin, w) = readFileOrStdin stdin args.fp w
+| args.lex = case contents of
+ (Right cs) = (lexer cs, Left "Parsing Disabled", w)
+ (Left e) = (Left e, Left "Parsing disabled", w)
+= case contents of
+ (Left e) = (Left e, Left "", w)
+ (Right cs)
+ # lexout = lexer cs
+ # parsout = parser lexout
+ # stdin = stdin <<< (either (const "") toString parsout)
+ # (_, w) = fclose stdin w
+ = (lexout, parser lexout, w)
+