/export/starexec/sandbox/solver/bin/starexec_run_standard /export/starexec/sandbox/benchmark/theBenchmark.hs /export/starexec/sandbox/output/output_files -------------------------------------------------------------------------------- MAYBE proof of /export/starexec/sandbox/benchmark/theBenchmark.hs # AProVE Commit ID: 794c25de1cacf0d048858bcd21c9a779e1221865 marcel 20200619 unpublished dirty H-Termination with start terms of the given HASKELL could not be shown: (0) HASKELL (1) LR [EQUIVALENT, 0 ms] (2) HASKELL (3) CR [EQUIVALENT, 0 ms] (4) HASKELL (5) IFR [EQUIVALENT, 0 ms] (6) HASKELL (7) BR [EQUIVALENT, 0 ms] (8) HASKELL (9) COR [EQUIVALENT, 73 ms] (10) HASKELL (11) LetRed [EQUIVALENT, 28 ms] (12) HASKELL (13) NumRed [SOUND, 0 ms] (14) HASKELL ---------------------------------------- (0) Obligation: mainModule Main module Main where { import qualified Prelude; } ---------------------------------------- (1) LR (EQUIVALENT) Lambda Reductions: The following Lambda expression "\vu54->case vu54 of { (ch,''' : t) -> if ch /= ''' : [] then (''' : ch ++ ''' : [],t) : [] else []; _ -> []} " is transformed to "lex0 vu54 = case vu54 of { (ch,''' : t) -> if ch /= ''' : [] then (''' : ch ++ ''' : [],t) : [] else []; _ -> []} ; " The following Lambda expression "\vu56->case vu56 of { (str,u) -> (ch ++ str,u) : []; _ -> []} " is transformed to "lexString0 ch vu56 = case vu56 of { (str,u) -> (ch ++ str,u) : []; _ -> []} ; " The following Lambda expression "\vu57->case vu57 of { (ch,t) -> concatMap (lexString0 ch) (lexString t); _ -> []} " is transformed to "lexString1 vu57 = case vu57 of { (ch,t) -> concatMap (lexString0 ch) (lexString t); _ -> []} ; " The following Lambda expression "\vu58->case vu58 of { '\' : t -> ([],t) : []; _ -> []} " is transformed to "lexStrItem0 vu58 = case vu58 of { '\' : t -> ([],t) : []; _ -> []} ; " The following Lambda expression "\vu55->case vu55 of { (str,t) -> ('"' : str,t) : []; _ -> []} " is transformed to "lex1 vu55 = case vu55 of { (str,t) -> ('"' : str,t) : []; _ -> []} ; " The following Lambda expression "\vu63->case vu63 of { (e,u) -> ('.' : ds ++ e,u) : []; _ -> []} " is transformed to "lexFracExp0 ds vu63 = case vu63 of { (e,u) -> ('.' : ds ++ e,u) : []; _ -> []} ; " The following Lambda expression "\vu64->case vu64 of { (ds,t) -> concatMap (lexFracExp0 ds) (lexExp t); _ -> []} " is transformed to "lexFracExp1 vu64 = case vu64 of { (ds,t) -> concatMap (lexFracExp0 ds) (lexExp t); _ -> []} ; " The following Lambda expression "\vu65->case vu65 of { (ds,u) -> (e : c : ds,u) : []; _ -> []} " is transformed to "lexExp0 e c vu65 = case vu65 of { (ds,u) -> (e : c : ds,u) : []; _ -> []} ; " The following Lambda expression "\vu66->case vu66 of { c : t -> if c `elem` '+' : '-' : [] then concatMap (lexExp0 e c) (lexDigits t) else []; _ -> []} " is transformed to "lexExp1 e vu66 = case vu66 of { c : t -> if c `elem` '+' : '-' : [] then concatMap (lexExp0 e c) (lexDigits t) else []; _ -> []} ; " The following Lambda expression "\vu67->case vu67 of { (ds,t) -> (e : ds,t) : []; _ -> []} " is transformed to "lexExp2 e vu67 = case vu67 of { (ds,t) -> (e : ds,t) : []; _ -> []} ; " The following Lambda expression "\vu59->case vu59 of { (sym,t) -> (c : sym,t) : []; _ -> []} " is transformed to "lex2 c vu59 = case vu59 of { (sym,t) -> (c : sym,t) : []; _ -> []} ; " The following Lambda expression "\vu60->case vu60 of { (nam,t) -> (c : nam,t) : []; _ -> []} " is transformed to "lex3 c vu60 = case vu60 of { (nam,t) -> (c : nam,t) : []; _ -> []} ; " The following Lambda expression "\vu61->case vu61 of { (fe,t) -> (c : ds ++ fe,t) : []; _ -> []} " is transformed to "lex4 c ds vu61 = case vu61 of { (fe,t) -> (c : ds ++ fe,t) : []; _ -> []} ; " The following Lambda expression "\vu62->case vu62 of { (ds,s) -> concatMap (lex4 c ds) (lexFracExp s); _ -> []} " is transformed to "lex5 c vu62 = case vu62 of { (ds,s) -> concatMap (lex4 c ds) (lexFracExp s); _ -> []} ; " The following Lambda expression "\ab->(a,b)" is transformed to "zip0 a b = (a,b); " The following Lambda expression "\vu68->case vu68 of { (cs@(_ : _),t) -> (cs,t) : []; _ -> []} " is transformed to "nonnull0 vu68 = case vu68 of { (cs@(_ : _),t) -> (cs,t) : []; _ -> []} ; " The following Lambda expression "\vu48->case vu48 of { (')' : [],u) -> (x,u) : []; _ -> []} " is transformed to "mandatory0 x vu48 = case vu48 of { (')' : [],u) -> (x,u) : []; _ -> []} ; " The following Lambda expression "\vu49->case vu49 of { (x,t) -> concatMap (mandatory0 x) (lex t); _ -> []} " is transformed to "mandatory1 vu49 = case vu49 of { (x,t) -> concatMap (mandatory0 x) (lex t); _ -> []} ; " The following Lambda expression "\vu50->case vu50 of { ('(' : [],s) -> concatMap mandatory1 (optional s); _ -> []} " is transformed to "mandatory2 vu50 = case vu50 of { ('(' : [],s) -> concatMap mandatory1 (optional s); _ -> []} ; " The following Lambda expression "\vu69->case vu69 of { ([],s') -> (mne,s') : []; _ -> []} " is transformed to "lexEsc0 mne vu69 = case vu69 of { ([],s') -> (mne,s') : []; _ -> []} ; " The following Lambda expression "\vu70->case vu70 of { (c,mne) -> concatMap (lexEsc0 mne) (lexmatch mne s : []); _ -> []} " is transformed to "lexEsc1 s vu70 = case vu70 of { (c,mne) -> concatMap (lexEsc0 mne) (lexmatch mne s : []); _ -> []} ; " The following Lambda expression "\(_,zs)->zs" is transformed to "zs0 (_,zs) = zs; " The following Lambda expression "\(ys,_)->ys" is transformed to "ys0 (ys,_) = ys; " The following Lambda expression "\lv1->case lv1 of { ('F' : 'a' : 'l' : 's' : 'e' : [],r0) -> (False,r0) : []; _ -> []} " is transformed to "readsPrec0 lv1 = case lv1 of { ('F' : 'a' : 'l' : 's' : 'e' : [],r0) -> (False,r0) : []; _ -> []} ; " The following Lambda expression "\lr1->concatMap readsPrec0 (lex lr1)" is transformed to "readsPrec1 lr1 = concatMap readsPrec0 (lex lr1); " The following Lambda expression "\lv1->case lv1 of { ('T' : 'r' : 'u' : 'e' : [],r0) -> (True,r0) : []; _ -> []} " is transformed to "readsPrec2 lv1 = case lv1 of { ('T' : 'r' : 'u' : 'e' : [],r0) -> (True,r0) : []; _ -> []} ; " The following Lambda expression "\lr2->concatMap readsPrec2 (lex lr2)" is transformed to "readsPrec3 lr2 = concatMap readsPrec2 (lex lr2); " ---------------------------------------- (2) Obligation: mainModule Main module Main where { import qualified Prelude; } ---------------------------------------- (3) CR (EQUIVALENT) Case Reductions: The following Case expression "case vu55 of { (str,t) -> ('"' : str,t) : []; _ -> []} " is transformed to "lex10 (str,t) = ('"' : str,t) : []; lex10 _ = []; " The following Case expression "case vu57 of { (ch,t) -> concatMap (lexString0 ch) (lexString t); _ -> []} " is transformed to "lexString10 (ch,t) = concatMap (lexString0 ch) (lexString t); lexString10 _ = []; " The following Case expression "case vu56 of { (str,u) -> (ch ++ str,u) : []; _ -> []} " is transformed to "lexString00 ch (str,u) = (ch ++ str,u) : []; lexString00 ch _ = []; " The following Case expression "case vu58 of { '\' : t -> ([],t) : []; _ -> []} " is transformed to "lexStrItem00 ('\' : t) = ([],t) : []; lexStrItem00 _ = []; " The following Case expression "case vu59 of { (sym,t) -> (c : sym,t) : []; _ -> []} " is transformed to "lex20 c (sym,t) = (c : sym,t) : []; lex20 c _ = []; " The following Case expression "case vu67 of { (ds,t) -> (e : ds,t) : []; _ -> []} " is transformed to "lexExp20 e (ds,t) = (e : ds,t) : []; lexExp20 e _ = []; " The following Case expression "case vu65 of { (ds,u) -> (e : c : ds,u) : []; _ -> []} " is transformed to "lexExp00 e c (ds,u) = (e : c : ds,u) : []; lexExp00 e c _ = []; " The following Case expression "case vu62 of { (ds,s) -> concatMap (lex4 c ds) (lexFracExp s); _ -> []} " is transformed to "lex50 c (ds,s) = concatMap (lex4 c ds) (lexFracExp s); lex50 c _ = []; " The following Case expression "case vu66 of { c : t -> if c `elem` '+' : '-' : [] then concatMap (lexExp0 e c) (lexDigits t) else []; _ -> []} " is transformed to "lexExp10 e (c : t) = if c `elem` '+' : '-' : [] then concatMap (lexExp0 e c) (lexDigits t) else []; lexExp10 e _ = []; " The following Case expression "case vu60 of { (nam,t) -> (c : nam,t) : []; _ -> []} " is transformed to "lex30 c (nam,t) = (c : nam,t) : []; lex30 c _ = []; " The following Case expression "case vu61 of { (fe,t) -> (c : ds ++ fe,t) : []; _ -> []} " is transformed to "lex40 c ds (fe,t) = (c : ds ++ fe,t) : []; lex40 c ds _ = []; " The following Case expression "case vu63 of { (e,u) -> ('.' : ds ++ e,u) : []; _ -> []} " is transformed to "lexFracExp00 ds (e,u) = ('.' : ds ++ e,u) : []; lexFracExp00 ds _ = []; " The following Case expression "case vu64 of { (ds,t) -> concatMap (lexFracExp0 ds) (lexExp t); _ -> []} " is transformed to "lexFracExp10 (ds,t) = concatMap (lexFracExp0 ds) (lexExp t); lexFracExp10 _ = []; " The following Case expression "case lv1 of { ('T' : 'r' : 'u' : 'e' : [],r0) -> (True,r0) : []; _ -> []} " is transformed to "readsPrec20 ('T' : 'r' : 'u' : 'e' : [],r0) = (True,r0) : []; readsPrec20 _ = []; " The following Case expression "case lv1 of { ('F' : 'a' : 'l' : 's' : 'e' : [],r0) -> (False,r0) : []; _ -> []} " is transformed to "readsPrec00 ('F' : 'a' : 'l' : 's' : 'e' : [],r0) = (False,r0) : []; readsPrec00 _ = []; " The following Case expression "case vu54 of { (ch,''' : t) -> if ch /= ''' : [] then (''' : ch ++ ''' : [],t) : [] else []; _ -> []} " is transformed to "lex00 (ch,''' : t) = if ch /= ''' : [] then (''' : ch ++ ''' : [],t) : [] else []; lex00 _ = []; " The following Case expression "case vu48 of { (')' : [],u) -> (x,u) : []; _ -> []} " is transformed to "mandatory00 x (')' : [],u) = (x,u) : []; mandatory00 x _ = []; " The following Case expression "case vu49 of { (x,t) -> concatMap (mandatory0 x) (lex t); _ -> []} " is transformed to "mandatory10 (x,t) = concatMap (mandatory0 x) (lex t); mandatory10 _ = []; " The following Case expression "case vu50 of { ('(' : [],s) -> concatMap mandatory1 (optional s); _ -> []} " is transformed to "mandatory20 ('(' : [],s) = concatMap mandatory1 (optional s); mandatory20 _ = []; " The following Case expression "case vu68 of { (cs@(_ : _),t) -> (cs,t) : []; _ -> []} " is transformed to "nonnull00 (cs@(_ : _),t) = (cs,t) : []; nonnull00 _ = []; " The following Case expression "case concatMap (lexEsc1 s) table of { pr : _ -> pr : []; [] -> []} " is transformed to "lexEsc2 (pr : _) = pr : []; lexEsc2 [] = []; " The following Case expression "case vu69 of { ([],s') -> (mne,s') : []; _ -> []} " is transformed to "lexEsc00 mne ([],s') = (mne,s') : []; lexEsc00 mne _ = []; " The following Case expression "case vu70 of { (c,mne) -> concatMap (lexEsc0 mne) (lexmatch mne s : []); _ -> []} " is transformed to "lexEsc10 s (c,mne) = concatMap (lexEsc0 mne) (lexmatch mne s : []); lexEsc10 s _ = []; " ---------------------------------------- (4) Obligation: mainModule Main module Main where { import qualified Prelude; } ---------------------------------------- (5) IFR (EQUIVALENT) If Reductions: The following If expression "if c `elem` '+' : '-' : [] then concatMap (lexExp0 e c) (lexDigits t) else []" is transformed to "lexExp100 e c t True = concatMap (lexExp0 e c) (lexDigits t); lexExp100 e c t False = []; " The following If expression "if b then mandatory else optional" is transformed to "readParen0 True = mandatory; readParen0 False = optional; " The following If expression "if ch /= ''' : [] then (''' : ch ++ ''' : [],t) : [] else []" is transformed to "lex000 ch t True = (''' : ch ++ ''' : [],t) : []; lex000 ch t False = []; " ---------------------------------------- (6) Obligation: mainModule Main module Main where { import qualified Prelude; } ---------------------------------------- (7) BR (EQUIVALENT) Replaced joker patterns by fresh variables and removed binding patterns. Binding Reductions: The bind variable of the following binding Pattern "cs@(vx : vy)" is replaced by the following term "vx : vy" The bind variable of the following binding Pattern "xs@(zy : zz)" is replaced by the following term "zy : zz" The bind variable of the following binding Pattern "s@(vuw : vux)" is replaced by the following term "vuw : vux" The bind variable of the following binding Pattern "xs@(vvw : vvx)" is replaced by the following term "vvw : vvx" ---------------------------------------- (8) Obligation: mainModule Main module Main where { import qualified Prelude; } ---------------------------------------- (9) COR (EQUIVALENT) Cond Reductions: The following Function with conditions "readsPrec00 ('F' : 'a' : 'l' : 's' : 'e' : [],r0) = (False,r0) : []; readsPrec00 wu = []; " is transformed to "readsPrec00 (vwz : vzy,r0) = readsPrec006 (vwz : vzy,r0); readsPrec00 wu = readsPrec000 wu; " "readsPrec000 wu = []; " "readsPrec001 True (vwz : vxv : vxx : vxz : vyv : [],r0) = (False,r0) : []; readsPrec001 vzz wuu = readsPrec000 wuu; " "readsPrec002 True (vwz : vxv : vxx : vxz : vyv : vyw,r0) = readsPrec001 (vyv == 'e') (vwz : vxv : vxx : vxz : vyv : vyw,r0); readsPrec002 wuv wuw = readsPrec000 wuw; " "readsPrec003 True (vwz : vxv : vxx : vxz : vyy,r0) = readsPrec002 (vxz == 's') (vwz : vxv : vxx : vxz : vyy,r0); readsPrec003 wux wuy = readsPrec000 wuy; " "readsPrec004 True (vwz : vxv : vxx : vzu,r0) = readsPrec003 (vxx == 'l') (vwz : vxv : vxx : vzu,r0); readsPrec004 wuz wvu = readsPrec000 wvu; " "readsPrec005 True (vwz : vxv : vzw,r0) = readsPrec004 (vxv == 'a') (vwz : vxv : vzw,r0); readsPrec005 wvv wvw = readsPrec000 wvw; " "readsPrec006 (vwz : vzy,r0) = readsPrec005 (vwz == 'F') (vwz : vzy,r0); readsPrec006 wvx = readsPrec000 wvx; " The following Function with conditions "takeWhile p [] = []; takeWhile p (x : xs)|p xx : takeWhile p xs|otherwise[]; " is transformed to "takeWhile p [] = takeWhile3 p []; takeWhile p (x : xs) = takeWhile2 p (x : xs); " "takeWhile0 p x xs True = []; " "takeWhile1 p x xs True = x : takeWhile p xs; takeWhile1 p x xs False = takeWhile0 p x xs otherwise; " "takeWhile2 p (x : xs) = takeWhile1 p x xs (p x); " "takeWhile3 p [] = []; takeWhile3 wwu wwv = takeWhile2 wwu wwv; " The following Function with conditions "lexString ('"' : s) = ('"' : [],s) : []; lexString s = concatMap lexString1 (lexStrItem s); " is transformed to "lexString (wwx : s) = lexString4 (wwx : s); lexString s = lexString2 s; " "lexString2 s = concatMap lexString1 (lexStrItem s); " "lexString3 True (wwx : s) = ('"' : [],s) : []; lexString3 wwy wwz = lexString2 wwz; " "lexString4 (wwx : s) = lexString3 (wwx == '"') (wwx : s); lexString4 wxu = lexString2 wxu; " The following Function with conditions "lexStrItem ('\' : '&' : s) = ('\' : '&' : [],s) : []; lexStrItem ('\' : c : s)|isSpace cconcatMap lexStrItem0 (dropWhile isSpace s : []); lexStrItem s = lexLitChar s; " is transformed to "lexStrItem (wyy : wzw) = lexStrItem7 (wyy : wzw); lexStrItem (wxw : wxz) = lexStrItem4 (wxw : wxz); lexStrItem s = lexStrItem1 s; " "lexStrItem1 s = lexLitChar s; " "lexStrItem2 wxw c s True = concatMap lexStrItem0 (dropWhile isSpace s : []); lexStrItem2 wxw c s False = lexStrItem1 (wxw : c : s); " "lexStrItem3 True (wxw : c : s) = lexStrItem2 wxw c s (isSpace c); lexStrItem3 wyu wyv = lexStrItem1 wyv; " "lexStrItem4 (wxw : wxz) = lexStrItem3 (wxw == '\') (wxw : wxz); lexStrItem4 wyw = lexStrItem1 wyw; " "lexStrItem5 True (wyy : wzu : s) = ('\' : '&' : [],s) : []; lexStrItem5 wzx wzy = lexStrItem4 wzy; " "lexStrItem6 True (wyy : wzu : s) = lexStrItem5 (wzu == '&') (wyy : wzu : s); lexStrItem6 wzz xuu = lexStrItem4 xuu; " "lexStrItem7 (wyy : wzw) = lexStrItem6 (wyy == '\') (wyy : wzw); lexStrItem7 xuv = lexStrItem4 xuv; " The following Function with conditions "lexStrItem00 ('\' : t) = ([],t) : []; lexStrItem00 wx = []; " is transformed to "lexStrItem00 (xux : t) = lexStrItem002 (xux : t); lexStrItem00 wx = lexStrItem000 wx; " "lexStrItem000 wx = []; " "lexStrItem001 True (xux : t) = ([],t) : []; lexStrItem001 xuy xuz = lexStrItem000 xuz; " "lexStrItem002 (xux : t) = lexStrItem001 (xux == '\') (xux : t); lexStrItem002 xvu = lexStrItem000 xvu; " The following Function with conditions "lexExp (e : s)|e `elem` 'e' : 'E' : []concatMap (lexExp1 e) (s : []) ++ concatMap (lexExp2 e) (lexDigits s); lexExp s = ([],s) : []; " is transformed to "lexExp (e : s) = lexExp5 (e : s); lexExp s = lexExp3 s; " "lexExp3 s = ([],s) : []; " "lexExp4 e s True = concatMap (lexExp1 e) (s : []) ++ concatMap (lexExp2 e) (lexDigits s); lexExp4 e s False = lexExp3 (e : s); " "lexExp5 (e : s) = lexExp4 e s (e `elem` 'e' : 'E' : []); lexExp5 xvw = lexExp3 xvw; " The following Function with conditions "lexFracExp ('.' : c : cs)|isDigit cconcatMap lexFracExp1 (lexDigits (c : cs)); lexFracExp s = lexExp s; " is transformed to "lexFracExp (xvy : xwv) = lexFracExp5 (xvy : xwv); lexFracExp s = lexFracExp2 s; " "lexFracExp2 s = lexExp s; " "lexFracExp3 xvy c cs True = concatMap lexFracExp1 (lexDigits (c : cs)); lexFracExp3 xvy c cs False = lexFracExp2 (xvy : c : cs); " "lexFracExp4 True (xvy : c : cs) = lexFracExp3 xvy c cs (isDigit c); lexFracExp4 xww xwx = lexFracExp2 xwx; " "lexFracExp5 (xvy : xwv) = lexFracExp4 (xvy == '.') (xvy : xwv); lexFracExp5 xwy = lexFracExp2 xwy; " The following Function with conditions "lex [] = ([],[]) : []; lex (c : s)|isSpace clex (dropWhile isSpace s); lex (''' : s) = concatMap lex0 (lexLitChar s); lex ('"' : s) = concatMap lex1 (lexString s) where { lex1 vu55 = lex10 vu55; ; lex10 (str,t) = ('"' : str,t) : []; lex10 wy = []; ; lexStrItem ('\' : '&' : s) = ('\' : '&' : [],s) : []; lexStrItem ('\' : c : s)|isSpace cconcatMap lexStrItem0 (dropWhile isSpace s : []); lexStrItem s = lexLitChar s; ; lexStrItem0 vu58 = lexStrItem00 vu58; ; lexStrItem00 ('\' : t) = ([],t) : []; lexStrItem00 wx = []; ; lexString ('"' : s) = ('"' : [],s) : []; lexString s = concatMap lexString1 (lexStrItem s); ; lexString0 ch vu56 = lexString00 ch vu56; ; lexString00 ch (str,u) = (ch ++ str,u) : []; lexString00 ch wv = []; ; lexString1 vu57 = lexString10 vu57; ; lexString10 (ch,t) = concatMap (lexString0 ch) (lexString t); lexString10 ww = []; } ; lex (c : s)|isSingle c(c : [],s) : []|isSym cconcatMap (lex2 c) (span isSym s : [])|isAlpha cconcatMap (lex3 c) (span isIdChar s : [])|isDigit cconcatMap (lex5 c) (span isDigit s : [])|otherwise[] where { isIdChar c = isAlphaNum c || c `elem` '_' : ''' : []; ; isSingle c = c `elem` ',' : ';' : '(' : ')' : '[' : ']' : '{' : '}' : '_' : '`' : []; ; isSym c = c `elem` '!' : '@' : '#' : '$' : '%' : '&' : '*' : '+' : '.' : '/' : '<' : '=' : '>' : '?' : '\' : '^' : '|' : ':' : '-' : '~' : []; ; lex2 c vu59 = lex20 c vu59; ; lex20 c (sym,t) = (c : sym,t) : []; lex20 c yu = []; ; lex3 c vu60 = lex30 c vu60; ; lex30 c (nam,t) = (c : nam,t) : []; lex30 c yv = []; ; lex4 c ds vu61 = lex40 c ds vu61; ; lex40 c ds (fe,t) = (c : ds ++ fe,t) : []; lex40 c ds xy = []; ; lex5 c vu62 = lex50 c vu62; ; lex50 c (ds,s) = concatMap (lex4 c ds) (lexFracExp s); lex50 c xz = []; ; lexExp (e : s)|e `elem` 'e' : 'E' : []concatMap (lexExp1 e) (s : []) ++ concatMap (lexExp2 e) (lexDigits s); lexExp s = ([],s) : []; ; lexExp0 e c vu65 = lexExp00 e c vu65; ; lexExp00 e c (ds,u) = (e : c : ds,u) : []; lexExp00 e c wz = []; ; lexExp1 e vu66 = lexExp10 e vu66; ; lexExp10 e (c : t) = lexExp100 e c t (c `elem` '+' : '-' : []); lexExp10 e xv = []; ; lexExp100 e c t True = concatMap (lexExp0 e c) (lexDigits t); lexExp100 e c t False = []; ; lexExp2 e vu67 = lexExp20 e vu67; ; lexExp20 e (ds,t) = (e : ds,t) : []; lexExp20 e xu = []; ; lexFracExp ('.' : c : cs)|isDigit cconcatMap lexFracExp1 (lexDigits (c : cs)); lexFracExp s = lexExp s; ; lexFracExp0 ds vu63 = lexFracExp00 ds vu63; ; lexFracExp00 ds (e,u) = ('.' : ds ++ e,u) : []; lexFracExp00 ds xx = []; ; lexFracExp1 vu64 = lexFracExp10 vu64; ; lexFracExp10 (ds,t) = concatMap (lexFracExp0 ds) (lexExp t); lexFracExp10 xw = []; } ; " is transformed to "lex [] = lex19 []; lex (c : s) = lex18 (c : s); lex (xyu : s) = lex16 (xyu : s); lex (xxv : s) = lex14 (xxv : s); lex (c : s) = lex12 (c : s); " "lex12 (c : s) = lex11 c s (isSingle c) where { isIdChar c = isAlphaNum c || c `elem` '_' : ''' : []; ; isSingle c = c `elem` ',' : ';' : '(' : ')' : '[' : ']' : '{' : '}' : '_' : '`' : []; ; isSym c = c `elem` '!' : '@' : '#' : '$' : '%' : '&' : '*' : '+' : '.' : '/' : '<' : '=' : '>' : '?' : '\' : '^' : '|' : ':' : '-' : '~' : []; ; lex11 c s True = (c : [],s) : []; lex11 c s False = lex9 c s (isSym c); ; lex2 c vu59 = lex20 c vu59; ; lex20 c (sym,t) = (c : sym,t) : []; lex20 c yu = []; ; lex3 c vu60 = lex30 c vu60; ; lex30 c (nam,t) = (c : nam,t) : []; lex30 c yv = []; ; lex4 c ds vu61 = lex40 c ds vu61; ; lex40 c ds (fe,t) = (c : ds ++ fe,t) : []; lex40 c ds xy = []; ; lex5 c vu62 = lex50 c vu62; ; lex50 c (ds,s) = concatMap (lex4 c ds) (lexFracExp s); lex50 c xz = []; ; lex6 c s True = []; ; lex7 c s True = concatMap (lex5 c) (span isDigit s : []); lex7 c s False = lex6 c s otherwise; ; lex8 c s True = concatMap (lex3 c) (span isIdChar s : []); lex8 c s False = lex7 c s (isDigit c); ; lex9 c s True = concatMap (lex2 c) (span isSym s : []); lex9 c s False = lex8 c s (isAlpha c); ; lexExp (e : s) = lexExp5 (e : s); lexExp s = lexExp3 s; ; lexExp0 e c vu65 = lexExp00 e c vu65; ; lexExp00 e c (ds,u) = (e : c : ds,u) : []; lexExp00 e c wz = []; ; lexExp1 e vu66 = lexExp10 e vu66; ; lexExp10 e (c : t) = lexExp100 e c t (c `elem` '+' : '-' : []); lexExp10 e xv = []; ; lexExp100 e c t True = concatMap (lexExp0 e c) (lexDigits t); lexExp100 e c t False = []; ; lexExp2 e vu67 = lexExp20 e vu67; ; lexExp20 e (ds,t) = (e : ds,t) : []; lexExp20 e xu = []; ; lexExp3 s = ([],s) : []; ; lexExp4 e s True = concatMap (lexExp1 e) (s : []) ++ concatMap (lexExp2 e) (lexDigits s); lexExp4 e s False = lexExp3 (e : s); ; lexExp5 (e : s) = lexExp4 e s (e `elem` 'e' : 'E' : []); lexExp5 xvw = lexExp3 xvw; ; lexFracExp (xvy : xwv) = lexFracExp5 (xvy : xwv); lexFracExp s = lexFracExp2 s; ; lexFracExp0 ds vu63 = lexFracExp00 ds vu63; ; lexFracExp00 ds (e,u) = ('.' : ds ++ e,u) : []; lexFracExp00 ds xx = []; ; lexFracExp1 vu64 = lexFracExp10 vu64; ; lexFracExp10 (ds,t) = concatMap (lexFracExp0 ds) (lexExp t); lexFracExp10 xw = []; ; lexFracExp2 s = lexExp s; ; lexFracExp3 xvy c cs True = concatMap lexFracExp1 (lexDigits (c : cs)); lexFracExp3 xvy c cs False = lexFracExp2 (xvy : c : cs); ; lexFracExp4 True (xvy : c : cs) = lexFracExp3 xvy c cs (isDigit c); lexFracExp4 xww xwx = lexFracExp2 xwx; ; lexFracExp5 (xvy : xwv) = lexFracExp4 (xvy == '.') (xvy : xwv); lexFracExp5 xwy = lexFracExp2 xwy; } ; " "lex13 True (xxv : s) = concatMap lex1 (lexString s) where { lex1 vu55 = lex10 vu55; ; lex10 (str,t) = ('"' : str,t) : []; lex10 wy = []; ; lexStrItem (wyy : wzw) = lexStrItem7 (wyy : wzw); lexStrItem (wxw : wxz) = lexStrItem4 (wxw : wxz); lexStrItem s = lexStrItem1 s; ; lexStrItem0 vu58 = lexStrItem00 vu58; ; lexStrItem00 (xux : t) = lexStrItem002 (xux : t); lexStrItem00 wx = lexStrItem000 wx; ; lexStrItem000 wx = []; ; lexStrItem001 True (xux : t) = ([],t) : []; lexStrItem001 xuy xuz = lexStrItem000 xuz; ; lexStrItem002 (xux : t) = lexStrItem001 (xux == '\') (xux : t); lexStrItem002 xvu = lexStrItem000 xvu; ; lexStrItem1 s = lexLitChar s; ; lexStrItem2 wxw c s True = concatMap lexStrItem0 (dropWhile isSpace s : []); lexStrItem2 wxw c s False = lexStrItem1 (wxw : c : s); ; lexStrItem3 True (wxw : c : s) = lexStrItem2 wxw c s (isSpace c); lexStrItem3 wyu wyv = lexStrItem1 wyv; ; lexStrItem4 (wxw : wxz) = lexStrItem3 (wxw == '\') (wxw : wxz); lexStrItem4 wyw = lexStrItem1 wyw; ; lexStrItem5 True (wyy : wzu : s) = ('\' : '&' : [],s) : []; lexStrItem5 wzx wzy = lexStrItem4 wzy; ; lexStrItem6 True (wyy : wzu : s) = lexStrItem5 (wzu == '&') (wyy : wzu : s); lexStrItem6 wzz xuu = lexStrItem4 xuu; ; lexStrItem7 (wyy : wzw) = lexStrItem6 (wyy == '\') (wyy : wzw); lexStrItem7 xuv = lexStrItem4 xuv; ; lexString (wwx : s) = lexString4 (wwx : s); lexString s = lexString2 s; ; lexString0 ch vu56 = lexString00 ch vu56; ; lexString00 ch (str,u) = (ch ++ str,u) : []; lexString00 ch wv = []; ; lexString1 vu57 = lexString10 vu57; ; lexString10 (ch,t) = concatMap (lexString0 ch) (lexString t); lexString10 ww = []; ; lexString2 s = concatMap lexString1 (lexStrItem s); ; lexString3 True (wwx : s) = ('"' : [],s) : []; lexString3 wwy wwz = lexString2 wwz; ; lexString4 (wwx : s) = lexString3 (wwx == '"') (wwx : s); lexString4 wxu = lexString2 wxu; } ; lex13 xxw xxx = lex12 xxx; " "lex14 (xxv : s) = lex13 (xxv == '"') (xxv : s); lex14 xxy = lex12 xxy; " "lex15 True (xyu : s) = concatMap lex0 (lexLitChar s); lex15 xyv xyw = lex14 xyw; " "lex16 (xyu : s) = lex15 (xyu == ''') (xyu : s); lex16 xyx = lex14 xyx; " "lex17 c s True = lex (dropWhile isSpace s); lex17 c s False = lex16 (c : s); " "lex18 (c : s) = lex17 c s (isSpace c); lex18 xyz = lex16 xyz; " "lex19 [] = ([],[]) : []; lex19 xzv = lex18 xzv; " The following Function with conditions "lexmatch (x : xs) (y : ys)|x == ylexmatch xs ys; lexmatch xs ys = (xs,ys); " is transformed to "lexmatch (x : xs) (y : ys) = lexmatch2 (x : xs) (y : ys); lexmatch xs ys = lexmatch0 xs ys; " "lexmatch0 xs ys = (xs,ys); " "lexmatch1 x xs y ys True = lexmatch xs ys; lexmatch1 x xs y ys False = lexmatch0 (x : xs) (y : ys); " "lexmatch2 (x : xs) (y : ys) = lexmatch1 x xs y ys (x == y); lexmatch2 xzy xzz = lexmatch0 xzy xzz; " The following Function with conditions "readsPrec20 ('T' : 'r' : 'u' : 'e' : [],r0) = (True,r0) : []; readsPrec20 yz = []; " is transformed to "readsPrec20 (yuw : ywx,r0) = readsPrec205 (yuw : ywx,r0); readsPrec20 yz = readsPrec200 yz; " "readsPrec200 yz = []; " "readsPrec201 True (yuw : yuy : yvu : yvw : [],r0) = (True,r0) : []; readsPrec201 ywy ywz = readsPrec200 ywz; " "readsPrec202 True (yuw : yuy : yvu : yvw : yvx,r0) = readsPrec201 (yvw == 'e') (yuw : yuy : yvu : yvw : yvx,r0); readsPrec202 yxu yxv = readsPrec200 yxv; " "readsPrec203 True (yuw : yuy : yvu : yvz,r0) = readsPrec202 (yvu == 'u') (yuw : yuy : yvu : yvz,r0); readsPrec203 yxw yxx = readsPrec200 yxx; " "readsPrec204 True (yuw : yuy : ywv,r0) = readsPrec203 (yuy == 'r') (yuw : yuy : ywv,r0); readsPrec204 yxy yxz = readsPrec200 yxz; " "readsPrec205 (yuw : ywx,r0) = readsPrec204 (yuw == 'T') (yuw : ywx,r0); readsPrec205 yyu = readsPrec200 yyu; " The following Function with conditions "undefined |Falseundefined; " is transformed to "undefined = undefined1; " "undefined0 True = undefined; " "undefined1 = undefined0 False; " The following Function with conditions "mandatory20 ('(' : [],s) = concatMap mandatory1 (optional s); mandatory20 zv = []; " is transformed to "mandatory20 (yyx : yyy,s) = mandatory202 (yyx : yyy,s); mandatory20 zv = mandatory200 zv; " "mandatory200 zv = []; " "mandatory201 True (yyx : [],s) = concatMap mandatory1 (optional s); mandatory201 yyz yzu = mandatory200 yzu; " "mandatory202 (yyx : yyy,s) = mandatory201 (yyx == '(') (yyx : yyy,s); mandatory202 yzv = mandatory200 yzv; " The following Function with conditions "mandatory00 x (')' : [],u) = (x,u) : []; mandatory00 x zw = []; " is transformed to "mandatory00 x (yzy : yzz,u) = mandatory002 x (yzy : yzz,u); mandatory00 x zw = mandatory000 x zw; " "mandatory000 x zw = []; " "mandatory001 True x (yzy : [],u) = (x,u) : []; mandatory001 zuu zuv zuw = mandatory000 zuv zuw; " "mandatory002 x (yzy : yzz,u) = mandatory001 (yzy == ')') x (yzy : yzz,u); mandatory002 zux zuy = mandatory000 zux zuy; " The following Function with conditions "dropWhile p [] = []; dropWhile p (zy : zz)|p zydropWhile p zz|otherwisezy : zz; " is transformed to "dropWhile p [] = dropWhile3 p []; dropWhile p (zy : zz) = dropWhile2 p (zy : zz); " "dropWhile1 p zy zz True = dropWhile p zz; dropWhile1 p zy zz False = dropWhile0 p zy zz otherwise; " "dropWhile0 p zy zz True = zy : zz; " "dropWhile2 p (zy : zz) = dropWhile1 p zy zz (p zy); " "dropWhile3 p [] = []; dropWhile3 zvv zvw = dropWhile2 zvv zvw; " The following Function with conditions "lex00 (ch,''' : t) = lex000 ch t (ch /= ''' : []); lex00 vuu = []; " is transformed to "lex00 (ch,zvz : t) = lex003 (ch,zvz : t); lex00 vuu = lex001 vuu; " "lex001 vuu = []; " "lex002 True (ch,zvz : t) = lex000 ch t (ch /= ''' : []); lex002 zwu zwv = lex001 zwv; " "lex003 (ch,zvz : t) = lex002 (zvz == ''') (ch,zvz : t); lex003 zww = lex001 zww; " The following Function with conditions "lexEsc (c : s)|c `elem` 'a' : 'b' : 'f' : 'n' : 'r' : 't' : 'v' : '\' : '"' : ''' : [](c : [],s) : []; lexEsc ('^' : c : s)|c >= '@' && c <= '_'('^' : c : [],s) : []; lexEsc ('o' : s) = prefix 'o' (span isOctDigit s) : []; lexEsc ('x' : s) = prefix 'x' (span isHexDigit s) : []; lexEsc (vuw : vux)|isDigit vuwspan isDigit (vuw : vux) : []|isUpper vuwlexEsc2 (concatMap (lexEsc1 (vuw : vux)) table); lexEsc vuy = []; " is transformed to "lexEsc (c : s) = lexEsc16 (c : s); lexEsc (zyy : zzv) = lexEsc14 (zyy : zzv); lexEsc (zxz : s) = lexEsc11 (zxz : s); lexEsc (zxu : s) = lexEsc8 (zxu : s); lexEsc (vuw : vux) = lexEsc6 (vuw : vux); lexEsc vuy = lexEsc3 vuy; " "lexEsc3 vuy = []; " "lexEsc5 vuw vux True = span isDigit (vuw : vux) : []; lexEsc5 vuw vux False = lexEsc4 vuw vux (isUpper vuw); " "lexEsc4 vuw vux True = lexEsc2 (concatMap (lexEsc1 (vuw : vux)) table); lexEsc4 vuw vux False = lexEsc3 (vuw : vux); " "lexEsc6 (vuw : vux) = lexEsc5 vuw vux (isDigit vuw); lexEsc6 zwy = lexEsc3 zwy; " "lexEsc7 True (zxu : s) = prefix 'x' (span isHexDigit s) : []; lexEsc7 zxv zxw = lexEsc6 zxw; " "lexEsc8 (zxu : s) = lexEsc7 (zxu == 'x') (zxu : s); lexEsc8 zxx = lexEsc6 zxx; " "lexEsc9 True (zxz : s) = prefix 'o' (span isOctDigit s) : []; lexEsc9 zyu zyv = lexEsc8 zyv; " "lexEsc11 (zxz : s) = lexEsc9 (zxz == 'o') (zxz : s); lexEsc11 zyw = lexEsc8 zyw; " "lexEsc12 zyy c s True = ('^' : c : [],s) : []; lexEsc12 zyy c s False = lexEsc11 (zyy : c : s); " "lexEsc13 True (zyy : c : s) = lexEsc12 zyy c s (c >= '@' && c <= '_'); lexEsc13 zzw zzx = lexEsc11 zzx; " "lexEsc14 (zyy : zzv) = lexEsc13 (zyy == '^') (zyy : zzv); lexEsc14 zzy = lexEsc11 zzy; " "lexEsc15 c s True = (c : [],s) : []; lexEsc15 c s False = lexEsc14 (c : s); " "lexEsc16 (c : s) = lexEsc15 c s (c `elem` 'a' : 'b' : 'f' : 'n' : 'r' : 't' : 'v' : '\' : '"' : ''' : []); lexEsc16 vuuu = lexEsc14 vuuu; " The following Function with conditions "lexLitChar [] = []; lexLitChar (c : s)|c /= '\'(c : [],s) : []|otherwisemap (prefix '\') (lexEsc s) where { lexEsc (c : s)|c `elem` 'a' : 'b' : 'f' : 'n' : 'r' : 't' : 'v' : '\' : '"' : ''' : [](c : [],s) : []; lexEsc ('^' : c : s)|c >= '@' && c <= '_'('^' : c : [],s) : []; lexEsc ('o' : s) = prefix 'o' (span isOctDigit s) : []; lexEsc ('x' : s) = prefix 'x' (span isHexDigit s) : []; lexEsc (vuw : vux)|isDigit vuwspan isDigit (vuw : vux) : []|isUpper vuwlexEsc2 (concatMap (lexEsc1 (vuw : vux)) table); lexEsc vuy = []; ; lexEsc0 mne vu69 = lexEsc00 mne vu69; ; lexEsc00 mne ([],s') = (mne,s') : []; lexEsc00 mne vvu = []; ; lexEsc1 s vu70 = lexEsc10 s vu70; ; lexEsc10 s (c,mne) = concatMap (lexEsc0 mne) (lexmatch mne s : []); lexEsc10 s vvv = []; ; lexEsc2 (pr : vuz) = pr : []; lexEsc2 [] = []; ; prefix c (t,s) = (c : t,s); ; table = ('\127','D' : 'E' : 'L' : []) : asciiTab; } ; " is transformed to "lexLitChar [] = lexLitChar3 []; lexLitChar (c : s) = lexLitChar2 (c : s); " "lexLitChar2 (c : s) = lexLitChar1 c s (c /= '\') where { lexEsc (c : s) = lexEsc16 (c : s); lexEsc (zyy : zzv) = lexEsc14 (zyy : zzv); lexEsc (zxz : s) = lexEsc11 (zxz : s); lexEsc (zxu : s) = lexEsc8 (zxu : s); lexEsc (vuw : vux) = lexEsc6 (vuw : vux); lexEsc vuy = lexEsc3 vuy; ; lexEsc0 mne vu69 = lexEsc00 mne vu69; ; lexEsc00 mne ([],s') = (mne,s') : []; lexEsc00 mne vvu = []; ; lexEsc1 s vu70 = lexEsc10 s vu70; ; lexEsc10 s (c,mne) = concatMap (lexEsc0 mne) (lexmatch mne s : []); lexEsc10 s vvv = []; ; lexEsc11 (zxz : s) = lexEsc9 (zxz == 'o') (zxz : s); lexEsc11 zyw = lexEsc8 zyw; ; lexEsc12 zyy c s True = ('^' : c : [],s) : []; lexEsc12 zyy c s False = lexEsc11 (zyy : c : s); ; lexEsc13 True (zyy : c : s) = lexEsc12 zyy c s (c >= '@' && c <= '_'); lexEsc13 zzw zzx = lexEsc11 zzx; ; lexEsc14 (zyy : zzv) = lexEsc13 (zyy == '^') (zyy : zzv); lexEsc14 zzy = lexEsc11 zzy; ; lexEsc15 c s True = (c : [],s) : []; lexEsc15 c s False = lexEsc14 (c : s); ; lexEsc16 (c : s) = lexEsc15 c s (c `elem` 'a' : 'b' : 'f' : 'n' : 'r' : 't' : 'v' : '\' : '"' : ''' : []); lexEsc16 vuuu = lexEsc14 vuuu; ; lexEsc2 (pr : vuz) = pr : []; lexEsc2 [] = []; ; lexEsc3 vuy = []; ; lexEsc4 vuw vux True = lexEsc2 (concatMap (lexEsc1 (vuw : vux)) table); lexEsc4 vuw vux False = lexEsc3 (vuw : vux); ; lexEsc5 vuw vux True = span isDigit (vuw : vux) : []; lexEsc5 vuw vux False = lexEsc4 vuw vux (isUpper vuw); ; lexEsc6 (vuw : vux) = lexEsc5 vuw vux (isDigit vuw); lexEsc6 zwy = lexEsc3 zwy; ; lexEsc7 True (zxu : s) = prefix 'x' (span isHexDigit s) : []; lexEsc7 zxv zxw = lexEsc6 zxw; ; lexEsc8 (zxu : s) = lexEsc7 (zxu == 'x') (zxu : s); lexEsc8 zxx = lexEsc6 zxx; ; lexEsc9 True (zxz : s) = prefix 'o' (span isOctDigit s) : []; lexEsc9 zyu zyv = lexEsc8 zyv; ; lexLitChar0 c s True = map (prefix '\') (lexEsc s); ; lexLitChar1 c s True = (c : [],s) : []; lexLitChar1 c s False = lexLitChar0 c s otherwise; ; prefix c (t,s) = (c : t,s); ; table = ('\127','D' : 'E' : 'L' : []) : asciiTab; } ; " "lexLitChar3 [] = []; lexLitChar3 vuux = lexLitChar2 vuux; " The following Function with conditions "span p [] = ([],[]); span p (vvw : vvx)|p vvw(vvw : ys,zs)|otherwise([],vvw : vvx) where { vu43 = span p vvx; ; ys = ys0 vu43; ; ys0 (ys,vvz) = ys; ; zs = zs0 vu43; ; zs0 (vvy,zs) = zs; } ; " is transformed to "span p [] = span3 p []; span p (vvw : vvx) = span2 p (vvw : vvx); " "span2 p (vvw : vvx) = span1 p vvw vvx (p vvw) where { span0 p vvw vvx True = ([],vvw : vvx); ; span1 p vvw vvx True = (vvw : ys,zs); span1 p vvw vvx False = span0 p vvw vvx otherwise; ; vu43 = span p vvx; ; ys = ys0 vu43; ; ys0 (ys,vvz) = ys; ; zs = zs0 vu43; ; zs0 (vvy,zs) = zs; } ; " "span3 p [] = ([],[]); span3 vuvu vuvv = span2 vuvu vuvv; " ---------------------------------------- (10) Obligation: mainModule Main module Main where { import qualified Prelude; } ---------------------------------------- (11) LetRed (EQUIVALENT) Let/Where Reductions: The bindings of the following Let/Where expression "lexLitChar1 c s (c /= '\') where { lexEsc (c : s) = lexEsc16 (c : s); lexEsc (zyy : zzv) = lexEsc14 (zyy : zzv); lexEsc (zxz : s) = lexEsc11 (zxz : s); lexEsc (zxu : s) = lexEsc8 (zxu : s); lexEsc (vuw : vux) = lexEsc6 (vuw : vux); lexEsc vuy = lexEsc3 vuy; ; lexEsc0 mne vu69 = lexEsc00 mne vu69; ; lexEsc00 mne ([],s') = (mne,s') : []; lexEsc00 mne vvu = []; ; lexEsc1 s vu70 = lexEsc10 s vu70; ; lexEsc10 s (c,mne) = concatMap (lexEsc0 mne) (lexmatch mne s : []); lexEsc10 s vvv = []; ; lexEsc11 (zxz : s) = lexEsc9 (zxz == 'o') (zxz : s); lexEsc11 zyw = lexEsc8 zyw; ; lexEsc12 zyy c s True = ('^' : c : [],s) : []; lexEsc12 zyy c s False = lexEsc11 (zyy : c : s); ; lexEsc13 True (zyy : c : s) = lexEsc12 zyy c s (c >= '@' && c <= '_'); lexEsc13 zzw zzx = lexEsc11 zzx; ; lexEsc14 (zyy : zzv) = lexEsc13 (zyy == '^') (zyy : zzv); lexEsc14 zzy = lexEsc11 zzy; ; lexEsc15 c s True = (c : [],s) : []; lexEsc15 c s False = lexEsc14 (c : s); ; lexEsc16 (c : s) = lexEsc15 c s (c `elem` 'a' : 'b' : 'f' : 'n' : 'r' : 't' : 'v' : '\' : '"' : ''' : []); lexEsc16 vuuu = lexEsc14 vuuu; ; lexEsc2 (pr : vuz) = pr : []; lexEsc2 [] = []; ; lexEsc3 vuy = []; ; lexEsc4 vuw vux True = lexEsc2 (concatMap (lexEsc1 (vuw : vux)) table); lexEsc4 vuw vux False = lexEsc3 (vuw : vux); ; lexEsc5 vuw vux True = span isDigit (vuw : vux) : []; lexEsc5 vuw vux False = lexEsc4 vuw vux (isUpper vuw); ; lexEsc6 (vuw : vux) = lexEsc5 vuw vux (isDigit vuw); lexEsc6 zwy = lexEsc3 zwy; ; lexEsc7 True (zxu : s) = prefix 'x' (span isHexDigit s) : []; lexEsc7 zxv zxw = lexEsc6 zxw; ; lexEsc8 (zxu : s) = lexEsc7 (zxu == 'x') (zxu : s); lexEsc8 zxx = lexEsc6 zxx; ; lexEsc9 True (zxz : s) = prefix 'o' (span isOctDigit s) : []; lexEsc9 zyu zyv = lexEsc8 zyv; ; lexLitChar0 c s True = map (prefix '\') (lexEsc s); ; lexLitChar1 c s True = (c : [],s) : []; lexLitChar1 c s False = lexLitChar0 c s otherwise; ; prefix c (t,s) = (c : t,s); ; table = ('\127','D' : 'E' : 'L' : []) : asciiTab; } " are unpacked to the following functions on top level "lexLitChar2LexEsc4 vuw vux True = lexLitChar2LexEsc2 (concatMap (lexLitChar2LexEsc1 (vuw : vux)) lexLitChar2Table); lexLitChar2LexEsc4 vuw vux False = lexLitChar2LexEsc3 (vuw : vux); " "lexLitChar2LexEsc5 vuw vux True = span isDigit (vuw : vux) : []; lexLitChar2LexEsc5 vuw vux False = lexLitChar2LexEsc4 vuw vux (isUpper vuw); " "lexLitChar2LexEsc10 s (c,mne) = concatMap (lexLitChar2LexEsc0 mne) (lexmatch mne s : []); lexLitChar2LexEsc10 s vvv = []; " "lexLitChar2LexEsc7 True (zxu : s) = lexLitChar2Prefix 'x' (span isHexDigit s) : []; lexLitChar2LexEsc7 zxv zxw = lexLitChar2LexEsc6 zxw; " "lexLitChar2LexEsc8 (zxu : s) = lexLitChar2LexEsc7 (zxu == 'x') (zxu : s); lexLitChar2LexEsc8 zxx = lexLitChar2LexEsc6 zxx; " "lexLitChar2LexEsc0 mne vu69 = lexLitChar2LexEsc00 mne vu69; " "lexLitChar2LexEsc9 True (zxz : s) = lexLitChar2Prefix 'o' (span isOctDigit s) : []; lexLitChar2LexEsc9 zyu zyv = lexLitChar2LexEsc8 zyv; " "lexLitChar2LexEsc15 c s True = (c : [],s) : []; lexLitChar2LexEsc15 c s False = lexLitChar2LexEsc14 (c : s); " "lexLitChar2LexEsc2 (pr : vuz) = pr : []; lexLitChar2LexEsc2 [] = []; " "lexLitChar2LexLitChar1 c s True = (c : [],s) : []; lexLitChar2LexLitChar1 c s False = lexLitChar2LexLitChar0 c s otherwise; " "lexLitChar2LexEsc13 True (zyy : c : s) = lexLitChar2LexEsc12 zyy c s (c >= '@' && c <= '_'); lexLitChar2LexEsc13 zzw zzx = lexLitChar2LexEsc11 zzx; " "lexLitChar2LexLitChar0 c s True = map (lexLitChar2Prefix '\') (lexLitChar2LexEsc s); " "lexLitChar2LexEsc (c : s) = lexLitChar2LexEsc16 (c : s); lexLitChar2LexEsc (zyy : zzv) = lexLitChar2LexEsc14 (zyy : zzv); lexLitChar2LexEsc (zxz : s) = lexLitChar2LexEsc11 (zxz : s); lexLitChar2LexEsc (zxu : s) = lexLitChar2LexEsc8 (zxu : s); lexLitChar2LexEsc (vuw : vux) = lexLitChar2LexEsc6 (vuw : vux); lexLitChar2LexEsc vuy = lexLitChar2LexEsc3 vuy; " "lexLitChar2LexEsc11 (zxz : s) = lexLitChar2LexEsc9 (zxz == 'o') (zxz : s); lexLitChar2LexEsc11 zyw = lexLitChar2LexEsc8 zyw; " "lexLitChar2LexEsc3 vuy = []; " "lexLitChar2LexEsc1 s vu70 = lexLitChar2LexEsc10 s vu70; " "lexLitChar2LexEsc00 mne ([],s') = (mne,s') : []; lexLitChar2LexEsc00 mne vvu = []; " "lexLitChar2LexEsc6 (vuw : vux) = lexLitChar2LexEsc5 vuw vux (isDigit vuw); lexLitChar2LexEsc6 zwy = lexLitChar2LexEsc3 zwy; " "lexLitChar2LexEsc16 (c : s) = lexLitChar2LexEsc15 c s (c `elem` 'a' : 'b' : 'f' : 'n' : 'r' : 't' : 'v' : '\' : '"' : ''' : []); lexLitChar2LexEsc16 vuuu = lexLitChar2LexEsc14 vuuu; " "lexLitChar2LexEsc14 (zyy : zzv) = lexLitChar2LexEsc13 (zyy == '^') (zyy : zzv); lexLitChar2LexEsc14 zzy = lexLitChar2LexEsc11 zzy; " "lexLitChar2Table = ('\127','D' : 'E' : 'L' : []) : asciiTab; " "lexLitChar2Prefix c (t,s) = (c : t,s); " "lexLitChar2LexEsc12 zyy c s True = ('^' : c : [],s) : []; lexLitChar2LexEsc12 zyy c s False = lexLitChar2LexEsc11 (zyy : c : s); " The bindings of the following Let/Where expression "concatMap lex1 (lexString s) where { lex1 vu55 = lex10 vu55; ; lex10 (str,t) = ('"' : str,t) : []; lex10 wy = []; ; lexStrItem (wyy : wzw) = lexStrItem7 (wyy : wzw); lexStrItem (wxw : wxz) = lexStrItem4 (wxw : wxz); lexStrItem s = lexStrItem1 s; ; lexStrItem0 vu58 = lexStrItem00 vu58; ; lexStrItem00 (xux : t) = lexStrItem002 (xux : t); lexStrItem00 wx = lexStrItem000 wx; ; lexStrItem000 wx = []; ; lexStrItem001 True (xux : t) = ([],t) : []; lexStrItem001 xuy xuz = lexStrItem000 xuz; ; lexStrItem002 (xux : t) = lexStrItem001 (xux == '\') (xux : t); lexStrItem002 xvu = lexStrItem000 xvu; ; lexStrItem1 s = lexLitChar s; ; lexStrItem2 wxw c s True = concatMap lexStrItem0 (dropWhile isSpace s : []); lexStrItem2 wxw c s False = lexStrItem1 (wxw : c : s); ; lexStrItem3 True (wxw : c : s) = lexStrItem2 wxw c s (isSpace c); lexStrItem3 wyu wyv = lexStrItem1 wyv; ; lexStrItem4 (wxw : wxz) = lexStrItem3 (wxw == '\') (wxw : wxz); lexStrItem4 wyw = lexStrItem1 wyw; ; lexStrItem5 True (wyy : wzu : s) = ('\' : '&' : [],s) : []; lexStrItem5 wzx wzy = lexStrItem4 wzy; ; lexStrItem6 True (wyy : wzu : s) = lexStrItem5 (wzu == '&') (wyy : wzu : s); lexStrItem6 wzz xuu = lexStrItem4 xuu; ; lexStrItem7 (wyy : wzw) = lexStrItem6 (wyy == '\') (wyy : wzw); lexStrItem7 xuv = lexStrItem4 xuv; ; lexString (wwx : s) = lexString4 (wwx : s); lexString s = lexString2 s; ; lexString0 ch vu56 = lexString00 ch vu56; ; lexString00 ch (str,u) = (ch ++ str,u) : []; lexString00 ch wv = []; ; lexString1 vu57 = lexString10 vu57; ; lexString10 (ch,t) = concatMap (lexString0 ch) (lexString t); lexString10 ww = []; ; lexString2 s = concatMap lexString1 (lexStrItem s); ; lexString3 True (wwx : s) = ('"' : [],s) : []; lexString3 wwy wwz = lexString2 wwz; ; lexString4 (wwx : s) = lexString3 (wwx == '"') (wwx : s); lexString4 wxu = lexString2 wxu; } " are unpacked to the following functions on top level "lex13LexString3 True (wwx : s) = ('"' : [],s) : []; lex13LexString3 wwy wwz = lex13LexString2 wwz; " "lex13LexStrItem5 True (wyy : wzu : s) = ('\' : '&' : [],s) : []; lex13LexStrItem5 wzx wzy = lex13LexStrItem4 wzy; " "lex13LexStrItem001 True (xux : t) = ([],t) : []; lex13LexStrItem001 xuy xuz = lex13LexStrItem000 xuz; " "lex13LexStrItem0 vu58 = lex13LexStrItem00 vu58; " "lex13LexString (wwx : s) = lex13LexString4 (wwx : s); lex13LexString s = lex13LexString2 s; " "lex13LexStrItem6 True (wyy : wzu : s) = lex13LexStrItem5 (wzu == '&') (wyy : wzu : s); lex13LexStrItem6 wzz xuu = lex13LexStrItem4 xuu; " "lex13LexString2 s = concatMap lex13LexString1 (lex13LexStrItem s); " "lex13LexStrItem1 s = lexLitChar s; " "lex13LexString10 (ch,t) = concatMap (lex13LexString0 ch) (lex13LexString t); lex13LexString10 ww = []; " "lex13Lex1 vu55 = lex13Lex10 vu55; " "lex13LexStrItem (wyy : wzw) = lex13LexStrItem7 (wyy : wzw); lex13LexStrItem (wxw : wxz) = lex13LexStrItem4 (wxw : wxz); lex13LexStrItem s = lex13LexStrItem1 s; " "lex13LexStrItem000 wx = []; " "lex13LexStrItem4 (wxw : wxz) = lex13LexStrItem3 (wxw == '\') (wxw : wxz); lex13LexStrItem4 wyw = lex13LexStrItem1 wyw; " "lex13LexString4 (wwx : s) = lex13LexString3 (wwx == '"') (wwx : s); lex13LexString4 wxu = lex13LexString2 wxu; " "lex13LexString00 ch (str,u) = (ch ++ str,u) : []; lex13LexString00 ch wv = []; " "lex13LexString0 ch vu56 = lex13LexString00 ch vu56; " "lex13LexStrItem2 wxw c s True = concatMap lex13LexStrItem0 (dropWhile isSpace s : []); lex13LexStrItem2 wxw c s False = lex13LexStrItem1 (wxw : c : s); " "lex13LexStrItem002 (xux : t) = lex13LexStrItem001 (xux == '\') (xux : t); lex13LexStrItem002 xvu = lex13LexStrItem000 xvu; " "lex13LexStrItem7 (wyy : wzw) = lex13LexStrItem6 (wyy == '\') (wyy : wzw); lex13LexStrItem7 xuv = lex13LexStrItem4 xuv; " "lex13LexStrItem00 (xux : t) = lex13LexStrItem002 (xux : t); lex13LexStrItem00 wx = lex13LexStrItem000 wx; " "lex13LexString1 vu57 = lex13LexString10 vu57; " "lex13Lex10 (str,t) = ('"' : str,t) : []; lex13Lex10 wy = []; " "lex13LexStrItem3 True (wxw : c : s) = lex13LexStrItem2 wxw c s (isSpace c); lex13LexStrItem3 wyu wyv = lex13LexStrItem1 wyv; " The bindings of the following Let/Where expression "span1 p vvw vvx (p vvw) where { span0 p vvw vvx True = ([],vvw : vvx); ; span1 p vvw vvx True = (vvw : ys,zs); span1 p vvw vvx False = span0 p vvw vvx otherwise; ; vu43 = span p vvx; ; ys = ys0 vu43; ; ys0 (ys,vvz) = ys; ; zs = zs0 vu43; ; zs0 (vvy,zs) = zs; } " are unpacked to the following functions on top level "span2Zs0 vuvw vuvx (vvy,zs) = zs; " "span2Vu43 vuvw vuvx = span vuvw vuvx; " "span2Ys vuvw vuvx = span2Ys0 vuvw vuvx (span2Vu43 vuvw vuvx); " "span2Span1 vuvw vuvx p vvw vvx True = (vvw : span2Ys vuvw vuvx,span2Zs vuvw vuvx); span2Span1 vuvw vuvx p vvw vvx False = span2Span0 vuvw vuvx p vvw vvx otherwise; " "span2Zs vuvw vuvx = span2Zs0 vuvw vuvx (span2Vu43 vuvw vuvx); " "span2Ys0 vuvw vuvx (ys,vvz) = ys; " "span2Span0 vuvw vuvx p vvw vvx True = ([],vvw : vvx); " The bindings of the following Let/Where expression "lex11 c s (isSingle c) where { isIdChar c = isAlphaNum c || c `elem` '_' : ''' : []; ; isSingle c = c `elem` ',' : ';' : '(' : ')' : '[' : ']' : '{' : '}' : '_' : '`' : []; ; isSym c = c `elem` '!' : '@' : '#' : '$' : '%' : '&' : '*' : '+' : '.' : '/' : '<' : '=' : '>' : '?' : '\' : '^' : '|' : ':' : '-' : '~' : []; ; lex11 c s True = (c : [],s) : []; lex11 c s False = lex9 c s (isSym c); ; lex2 c vu59 = lex20 c vu59; ; lex20 c (sym,t) = (c : sym,t) : []; lex20 c yu = []; ; lex3 c vu60 = lex30 c vu60; ; lex30 c (nam,t) = (c : nam,t) : []; lex30 c yv = []; ; lex4 c ds vu61 = lex40 c ds vu61; ; lex40 c ds (fe,t) = (c : ds ++ fe,t) : []; lex40 c ds xy = []; ; lex5 c vu62 = lex50 c vu62; ; lex50 c (ds,s) = concatMap (lex4 c ds) (lexFracExp s); lex50 c xz = []; ; lex6 c s True = []; ; lex7 c s True = concatMap (lex5 c) (span isDigit s : []); lex7 c s False = lex6 c s otherwise; ; lex8 c s True = concatMap (lex3 c) (span isIdChar s : []); lex8 c s False = lex7 c s (isDigit c); ; lex9 c s True = concatMap (lex2 c) (span isSym s : []); lex9 c s False = lex8 c s (isAlpha c); ; lexExp (e : s) = lexExp5 (e : s); lexExp s = lexExp3 s; ; lexExp0 e c vu65 = lexExp00 e c vu65; ; lexExp00 e c (ds,u) = (e : c : ds,u) : []; lexExp00 e c wz = []; ; lexExp1 e vu66 = lexExp10 e vu66; ; lexExp10 e (c : t) = lexExp100 e c t (c `elem` '+' : '-' : []); lexExp10 e xv = []; ; lexExp100 e c t True = concatMap (lexExp0 e c) (lexDigits t); lexExp100 e c t False = []; ; lexExp2 e vu67 = lexExp20 e vu67; ; lexExp20 e (ds,t) = (e : ds,t) : []; lexExp20 e xu = []; ; lexExp3 s = ([],s) : []; ; lexExp4 e s True = concatMap (lexExp1 e) (s : []) ++ concatMap (lexExp2 e) (lexDigits s); lexExp4 e s False = lexExp3 (e : s); ; lexExp5 (e : s) = lexExp4 e s (e `elem` 'e' : 'E' : []); lexExp5 xvw = lexExp3 xvw; ; lexFracExp (xvy : xwv) = lexFracExp5 (xvy : xwv); lexFracExp s = lexFracExp2 s; ; lexFracExp0 ds vu63 = lexFracExp00 ds vu63; ; lexFracExp00 ds (e,u) = ('.' : ds ++ e,u) : []; lexFracExp00 ds xx = []; ; lexFracExp1 vu64 = lexFracExp10 vu64; ; lexFracExp10 (ds,t) = concatMap (lexFracExp0 ds) (lexExp t); lexFracExp10 xw = []; ; lexFracExp2 s = lexExp s; ; lexFracExp3 xvy c cs True = concatMap lexFracExp1 (lexDigits (c : cs)); lexFracExp3 xvy c cs False = lexFracExp2 (xvy : c : cs); ; lexFracExp4 True (xvy : c : cs) = lexFracExp3 xvy c cs (isDigit c); lexFracExp4 xww xwx = lexFracExp2 xwx; ; lexFracExp5 (xvy : xwv) = lexFracExp4 (xvy == '.') (xvy : xwv); lexFracExp5 xwy = lexFracExp2 xwy; } " are unpacked to the following functions on top level "lex12Lex7 c s True = concatMap (lex12Lex5 c) (span isDigit s : []); lex12Lex7 c s False = lex12Lex6 c s otherwise; " "lex12LexExp00 e c (ds,u) = (e : c : ds,u) : []; lex12LexExp00 e c wz = []; " "lex12LexExp20 e (ds,t) = (e : ds,t) : []; lex12LexExp20 e xu = []; " "lex12Lex2 c vu59 = lex12Lex20 c vu59; " "lex12Lex4 c ds vu61 = lex12Lex40 c ds vu61; " "lex12IsSym c = c `elem` '!' : '@' : '#' : '$' : '%' : '&' : '*' : '+' : '.' : '/' : '<' : '=' : '>' : '?' : '\' : '^' : '|' : ':' : '-' : '~' : []; " "lex12LexExp1 e vu66 = lex12LexExp10 e vu66; " "lex12LexFracExp (xvy : xwv) = lex12LexFracExp5 (xvy : xwv); lex12LexFracExp s = lex12LexFracExp2 s; " "lex12LexExp100 e c t True = concatMap (lex12LexExp0 e c) (lexDigits t); lex12LexExp100 e c t False = []; " "lex12LexExp5 (e : s) = lex12LexExp4 e s (e `elem` 'e' : 'E' : []); lex12LexExp5 xvw = lex12LexExp3 xvw; " "lex12Lex50 c (ds,s) = concatMap (lex12Lex4 c ds) (lex12LexFracExp s); lex12Lex50 c xz = []; " "lex12Lex5 c vu62 = lex12Lex50 c vu62; " "lex12Lex8 c s True = concatMap (lex12Lex3 c) (span lex12IsIdChar s : []); lex12Lex8 c s False = lex12Lex7 c s (isDigit c); " "lex12IsIdChar c = isAlphaNum c || c `elem` '_' : ''' : []; " "lex12LexFracExp3 xvy c cs True = concatMap lex12LexFracExp1 (lexDigits (c : cs)); lex12LexFracExp3 xvy c cs False = lex12LexFracExp2 (xvy : c : cs); " "lex12Lex20 c (sym,t) = (c : sym,t) : []; lex12Lex20 c yu = []; " "lex12LexFracExp4 True (xvy : c : cs) = lex12LexFracExp3 xvy c cs (isDigit c); lex12LexFracExp4 xww xwx = lex12LexFracExp2 xwx; " "lex12LexExp (e : s) = lex12LexExp5 (e : s); lex12LexExp s = lex12LexExp3 s; " "lex12LexExp4 e s True = concatMap (lex12LexExp1 e) (s : []) ++ concatMap (lex12LexExp2 e) (lexDigits s); lex12LexExp4 e s False = lex12LexExp3 (e : s); " "lex12Lex3 c vu60 = lex12Lex30 c vu60; " "lex12IsSingle c = c `elem` ',' : ';' : '(' : ')' : '[' : ']' : '{' : '}' : '_' : '`' : []; " "lex12Lex6 c s True = []; " "lex12Lex11 c s True = (c : [],s) : []; lex12Lex11 c s False = lex12Lex9 c s (lex12IsSym c); " "lex12LexFracExp5 (xvy : xwv) = lex12LexFracExp4 (xvy == '.') (xvy : xwv); lex12LexFracExp5 xwy = lex12LexFracExp2 xwy; " "lex12Lex30 c (nam,t) = (c : nam,t) : []; lex12Lex30 c yv = []; " "lex12LexExp10 e (c : t) = lex12LexExp100 e c t (c `elem` '+' : '-' : []); lex12LexExp10 e xv = []; " "lex12Lex9 c s True = concatMap (lex12Lex2 c) (span lex12IsSym s : []); lex12Lex9 c s False = lex12Lex8 c s (isAlpha c); " "lex12LexFracExp0 ds vu63 = lex12LexFracExp00 ds vu63; " "lex12LexFracExp10 (ds,t) = concatMap (lex12LexFracExp0 ds) (lex12LexExp t); lex12LexFracExp10 xw = []; " "lex12LexExp2 e vu67 = lex12LexExp20 e vu67; " "lex12LexFracExp1 vu64 = lex12LexFracExp10 vu64; " "lex12LexFracExp2 s = lex12LexExp s; " "lex12LexExp3 s = ([],s) : []; " "lex12Lex40 c ds (fe,t) = (c : ds ++ fe,t) : []; lex12Lex40 c ds xy = []; " "lex12LexFracExp00 ds (e,u) = ('.' : ds ++ e,u) : []; lex12LexFracExp00 ds xx = []; " "lex12LexExp0 e c vu65 = lex12LexExp00 e c vu65; " The bindings of the following Let/Where expression "readParen0 b where { mandatory r = concatMap mandatory2 (lex r); ; mandatory0 x vu48 = mandatory00 x vu48; ; mandatory00 x (yzy : yzz,u) = mandatory002 x (yzy : yzz,u); mandatory00 x zw = mandatory000 x zw; ; mandatory000 x zw = []; ; mandatory001 True x (yzy : [],u) = (x,u) : []; mandatory001 zuu zuv zuw = mandatory000 zuv zuw; ; mandatory002 x (yzy : yzz,u) = mandatory001 (yzy == ')') x (yzy : yzz,u); mandatory002 zux zuy = mandatory000 zux zuy; ; mandatory1 vu49 = mandatory10 vu49; ; mandatory10 (x,t) = concatMap (mandatory0 x) (lex t); mandatory10 zx = []; ; mandatory2 vu50 = mandatory20 vu50; ; mandatory20 (yyx : yyy,s) = mandatory202 (yyx : yyy,s); mandatory20 zv = mandatory200 zv; ; mandatory200 zv = []; ; mandatory201 True (yyx : [],s) = concatMap mandatory1 (optional s); mandatory201 yyz yzu = mandatory200 yzu; ; mandatory202 (yyx : yyy,s) = mandatory201 (yyx == '(') (yyx : yyy,s); mandatory202 yzv = mandatory200 yzv; ; optional r = g r ++ mandatory r; ; readParen0 True = mandatory; readParen0 False = optional; } " are unpacked to the following functions on top level "readParenMandatory20 vuvy (yyx : yyy,s) = readParenMandatory202 vuvy (yyx : yyy,s); readParenMandatory20 vuvy zv = readParenMandatory200 vuvy zv; " "readParenMandatory00 vuvy x (yzy : yzz,u) = readParenMandatory002 vuvy x (yzy : yzz,u); readParenMandatory00 vuvy x zw = readParenMandatory000 vuvy x zw; " "readParenMandatory202 vuvy (yyx : yyy,s) = readParenMandatory201 vuvy (yyx == '(') (yyx : yyy,s); readParenMandatory202 vuvy yzv = readParenMandatory200 vuvy yzv; " "readParenMandatory002 vuvy x (yzy : yzz,u) = readParenMandatory001 vuvy (yzy == ')') x (yzy : yzz,u); readParenMandatory002 vuvy zux zuy = readParenMandatory000 vuvy zux zuy; " "readParenMandatory201 vuvy True (yyx : [],s) = concatMap (readParenMandatory1 vuvy) (readParenOptional vuvy s); readParenMandatory201 vuvy yyz yzu = readParenMandatory200 vuvy yzu; " "readParenMandatory001 vuvy True x (yzy : [],u) = (x,u) : []; readParenMandatory001 vuvy zuu zuv zuw = readParenMandatory000 vuvy zuv zuw; " "readParenMandatory10 vuvy (x,t) = concatMap (readParenMandatory0 vuvy x) (lex t); readParenMandatory10 vuvy zx = []; " "readParenMandatory2 vuvy vu50 = readParenMandatory20 vuvy vu50; " "readParenReadParen0 vuvy True = readParenMandatory vuvy; readParenReadParen0 vuvy False = readParenOptional vuvy; " "readParenMandatory0 vuvy x vu48 = readParenMandatory00 vuvy x vu48; " "readParenMandatory200 vuvy zv = []; " "readParenOptional vuvy r = vuvy r ++ readParenMandatory vuvy r; " "readParenMandatory000 vuvy x zw = []; " "readParenMandatory1 vuvy vu49 = readParenMandatory10 vuvy vu49; " "readParenMandatory vuvy r = concatMap (readParenMandatory2 vuvy) (lex r); " ---------------------------------------- (12) Obligation: mainModule Main module Main where { import qualified Prelude; } ---------------------------------------- (13) NumRed (SOUND) Num Reduction:All numbers are transformed to their corresponding representation with Succ, Pred and Zero. ---------------------------------------- (14) Obligation: mainModule Main module Main where { import qualified Prelude; }