h& ت $      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKL M NOP Q R S T U VWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~               !"""""""""""""""""""########$$$$$$$$$$$$$$$$$$$$$$$$$$$$%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%&&&&&&&&&&&&&&''''''''''''''''''''(((((((((((((((()))))))))))))))))))))))))))))))))))))******+++,,,,,,,,,,,,,,,,,,----..........///////////////////////////////0000000000000000000000000001111111111111111111111111111111111111111111111112222233333333333333334444444444455555555555555555555555555666777777777778888888888888888888899999999999999999999999999                   ::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::;;;;;;;;;;;<<<<<<<<<<<<<<<<<<======================= = = = = = = = = = = = = = = = = = = = = = = = = =                    > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > >                                             ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A A B B B B B B B B B B B B B                                     C C C C C C C C C C C C C C C C C C C C C C C C C C C C C C C C D D D D D D D D D D D D D D D D E E E E E E F F F F F F F F F F F F F F F F F F F F F F F F F F F F F F F F F F F F F F F F F G G G G G G G G G G G G G G G G G G G G G G G G G G G G G G G G G G G G G G G G G G H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H H HHHHHHHHHHHHHHHHHHHHIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJKKKKKKKKKKKKKKKKKKKKLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNNOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOPPPPPPPPPPPPPPPPPPPPPPPPPPQQQQQQQQQQQQQQQQQQQQQQQQQQQQRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRSSSSSSSSSSSSSSSSTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUVVVVVVVVVVVVVVVVVVWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWXYYZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZ Z Z Z Z Z Z Z Z Z Z Z Z Z [ [ [ \ ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ] ]!]!]!]!]!]!]!]!]!]!]!]!]!]!]!]!]!]!]!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!^!_!_!_!_!_!_!_!_!_!_!_!_!_!_!`!`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"`"a"a"a"a"a"b"b"b"b"b"b"b"b"b"b"b"b"b"b"b"b"b"b"b"b"b"b"b"c"c"c"c"c"c"c"c"c"c"c"c"c"c"c"c"c"c#c#c#c#c#c#c#c#d#d#d#d#d#d#d#d#d#d#d#d#d#d#d#d#d#d#e#e#e#e#e#e#e#e#e#e#e#e#e#e#e#e#e#e#e#e#e#e#e#e#e#e#e#e#e#e#e#e#e#e#e#e#e#e#e#e#e#e#e#e#e#e#e#e#e#e#e#e#e#e#e#f#f#f#f#f#f#f#f#f#f#f#f#f#f#f#f#f#f#f#f#f#f#f#f#f#f#f#f#f#f#f#f#f#f#f#f#f#f#f#f#f#f#f#f#f#f#f#f$f$f$f$f$f$f$f$f$f$f$f$f$f$f$f$f$f$f$f$f$f$f$f$f$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$g$h$i$i$i$i$i$i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%i%j%j%j%j%j%j%j%j%j%j%j%j&j&j&j&j&j&j&j&j&j&j&j&j&j&j&j&j&j&j&j&j&j&j&j&j&j&j&j&j&j&j&j&j&j&j&j&j&j&j&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k&k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k'k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k(k)k)k)k)k)k)k)k)k)k)k)k)k)k)k)k)k)k)k)k)k)k)k)k)k)k)k)k)k)k)k)k)k)k)k)k)k)k)k)k)k)k)k)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)l)m*m*m*m*m*m*m*m*m*m*m*m*m*m*m*m*m*m*m*m*m*m*m*m*m*m*m*m*m*m*m*m*m*m*m*m*m*m*m*m*m*m*m*m*m*m*n*n*n*n*n*n*n*n*n*n*n*n*n*n*n*n*n*n*n*n*n*n*n*n*n*n*n*n*n*n*n*n*n*n*n*n*n*n*n*n*n*n*n*n*n*n*n*n*n*n*n*n*n*o*o*o*o*o*o*o*o*o*o*o*o*o*o*o*o*o*o*o*o*o*o*o*o*o*o*o*o*o*o+o+o+o+o+o+o+o+o+o+o+o+o+o+o+o+o+o+o+o+o+o+o+o+o+p+p+p+p+p+p+p+p+p+p+p+p+p+p+p+p+p+p+p+p+p+p+p+p+p+p+p+p+p+p+p+p+p+p+p+p+p+p+p+p+p+p+p+p+p+p+p+p+q+q+q+q+q+q+q+q+q+q+q+q+q+q+q+q+q+q+q+q+q+q+q+q+q+q+q+q+q+q+q+q+q+q+q+q+q+q+q+r+r+r+r+r+r+r+r+r+r+r+r+r+r+r+r+r,r,r,r,r,r,r,r,r,r,r,r,r,r,r,r,r,r,s,s,s,s,s,s,s,s,s,s,s,s,s,s,s,s,s,s,s,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t,t-t-t-t-t-t-t-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-u-v-v-v-v-v-v-v-v-v-v-v-v-v-v-v-v-v-v-v-v-v-v-v-v-v-v-v-v-v-v-v-v-v-v-v-v-v-v-v-v-v-v-v-v-v-v.v.v.v.v.v.v.v.v.w.w.w.w.w.w.w.w.w.w.w.w.w.w.w.w.w.w.w.w.w.w.w.w.w.w.w.w.w.w.w.w.x.x.x.x.x.x.x.x.x.x.x.x.x.x.x.x.x.x.x.x.x.x.x. . . . . . . . . . .y.y.y.y.y.y.y.y.y.y.y.y.y.y.y.y.y.y.y.y.y.y.y.y.y.y.y.y.y.y.y.y.y.y.y.y.y.y.y.y.y.y.y.y.y.y.y.y.y.y.y.y.y.y.y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y/y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y0y1y1y1y1y1y1y1y1y1y1y1y1y1y1y1y1y1y1y1y1y1y1y1y1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z1z2z2z2z2z2z2z2z2z2z2z2z2z2z2z2z2z2z2z2z2z2z2z2z2z2z2z2z2z2z2z2z2z2z2z2z2z2z2z2z2z2z2z2z2z2z2z2z2z2z2z2z2z2z2z2z2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{2{3{3{3{3{3{3{3{3{3{3{3{3{3{3{3{3{3{3{3{3{3{3{3{3{3{3{3{3{3{3{3{3{3{3{3{3{3{3{3{3{3{3{3{3{3{3{3{3{3{3{3{3{3{3{3|3|3|3|3|3|3|3|3|3|3|3|3|3|3|3|3|3|3|3|3|3}3}3}3}3}3}3}3}3}3}3}3}3}3}3}3}3}3}3}3}3}3}3}3}3}3}3}3}3}3}3}3}3}3}3}3}3}3}3}3}3}3}3}3}3}3}3}3}3}3}3~3~3~4~4~4~4~4~4~4~4~4~4~4~4~4~4~4~4~4~4~4~4~4~4~4~4~4~4~4~4~44444444444444444444444444444444444444444444444444444444444444444444444444444444444444444444444444445555555555555555555555555555555555555555555555555555555555555555555555555555555555555555555555555555555555555555555555555555555566666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777778888888888888888888888888888888888888888888888888888888888888888888888888888888888888888888888888888888888888888888888888888888899999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<================================================================================================================================>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????????@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCDDDDDDDDDDDDDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSDSESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESESFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSFSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSGSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSHSISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISISJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSJSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSKSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSLSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSMSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSNSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSOSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSPSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQSQQQQQQQQQQQQQQQQQQQQQQQQQQQQQRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRR[R[R[R[R[R[R[R[R[R[R[R[R[R[R[R[R[R[R[R[R[R[R[R[R[R[R[R[R[R[R[R[R[R[R[R[R[R[R[R[R[R[R[R[R[R[R[R[R[R[R[R[R[RRRRRSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSS[S[S[S[S[S[S[S[SSSSSSS[S[S[S[S[S[S[S[S[SSS[SSSSSSSSSSSSSSSSSSSS[S[S[S[S[S[S[S[S[S[SSSSSSSSSSSSSSSSSSSSTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUU|U|U|U|U|U|U|U|U|U|U|U|U|U|U|U|U|U|U|U|U|U|U|U|U|U|U|U|U|U|U|U|U|U|U|U|U|V|V|V|V|V|V|V|V|V|V|V|V|V|VVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVV[V[V[V[V[V[V[V[V[V[VVVVVVV[V[V[V[V[V[V[V[V[V[V[V[V[V[V[V[V[V[V[V[V[V[V[W[W[W[W[W[W[W[W[W[W[W[W[W[W[W[W[W[W[W[W[W[W[W[W[W[W[W[WWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWWXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZ[Z[Z[Z[Z[Z[Z[Z[Z[Z[Z[Z[Z[Z[Z[Z[Z[Z[Z[Z[Z[Z[Z[Z[Z[Z[Z[Z[Z[Z[Z[Z[Z[Z[Z[Z[Z[Z[Z[Z[Z[Z[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[\[][][][][][][][][][][][][][][][][][][][][][][]]]]]]]]]]]][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^______________________________________________________________________________[_[_[_[_[_[_[_[_[_[_[_[_[_[_[_[_[_[_[_[_[_[_[_[_[_[_[_[_[_[_[_[_[_[_[_[_[_[_[_[_[_[_[_[_[_[_[_[_[_[_[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[``````````````````````[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[`[a[a[a[a[a[a[a[aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaabbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddddeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffgggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggghhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiijjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkkllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllllmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppppqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttttt t t t t t t t t t t t t t t t t t t t t t t t t t t t t t t t t t t t t t t t t t t t t t t t t t t t t t u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u uuuuuuuuuuuuuuuuuuuuuuuuuuuuuuvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx[xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyzzzzzzzzzzzzzz[zzzzzzzzzzzzz[z[z[z[zzzzzzzzzzzzzzzzzzzzzz[z[z[zzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{|||||||||||||||||||||[|[|[|[|[|[|[|[|[|[|[|[|[|[|[|[|[|[|[|[|[|[|[|[|[|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Safe-Inferred!!$%&.145789:;VoAgda1Agda42Agda71Agda154AgdaReturn the error corresponding to an exit code from the Agda process J J Safe-Inferred#!$%&().145789:;Y:~AgdaRecords already processed entities and maps them to an internal identifier.~AgdaSupply of internal identifiers.~AgdaNames connected to an entity~Agda'Rendering that entity's name to a label~AgdaGraph structure~AgdaInternal module identifiers for construction of dependency graph.~Agda*Translate an entity name into an internal ~ . Returns True if the  ModuleName is new, i.e., has not been encountered before and is thus added to the map of processed modules.~Agda%Add an arc from importer to imported. ~~~~~~~~~~~ Safe-Inferred!!$%&.145789:;ZqAgdaCut off structural order comparison at some depth in termination checker?Agdac >= 0( means: record decrease up to including c+1.AgdaThe default termination depth. Safe-Inferred!!$%&.145789:;\Agda Semirings.Agda Addition.AgdaMultiplication.AgdaZero. The one is never used in matrix multiplication , one :: a -- ^ One.AgdaHasZero is needed for sparse matrices, to tell which is the element that does not have to be stored. It is a cut-down version of SemiRing, which is definable without the implicit ?cutoff.AgdaThe standard semiring on ~s.AgdaThe standard semiring on ~s.AgdaThe standard semiring on ~s.   Safe-Inferred!!$%&.145789:;]AgdaA constant term.Agda,A term with one hole and the (old) contents.Agda%A term with many holes (error value). Safe-Inferred!!$%&.145789:;_AgdaBetter name for ~.AgdaGuard: return the action f only if the boolean is TrueAgdaGuard: return the value a only if the boolean is TrueAgdaBranch over a ~ collection of values.AgdaBranch over a ~3 collection of values using the supplied action. Safe-Inferred!!$%&.145789:;eAgdaType of a filter for CallSiteAgdaType of an entry in a  CallStackAgdaType of a column of a SrcLocAgdaType of a line number of a SrcLocAgdaType of a filename of a SrcLoc | e.g. `srcfullAgdaUtilsFoo.hs`Agda$Type of the name of a function in a CallSite | e.g. proveEverythingAgdaType of the module name of a SrcLoc | e.g. AgdaType of the package name of a SrcLoc | e.g. `Agda-2.@`Agda1The same as the un-exported internal function in %GHC.Exceptions (prettyCallStackLines) Prints like: +doFoo, called at foo.hs:190:24 in main:MainAgdaPretty-print a  CallStack". This has a few differences from GHC.Stack.prettyCallStackLines. We omit the "CallStack (from GetCallStack)" header line for brevity. If there is only one entry (which is common, due to the manual nature of the  HasCallStack constraint), shows the entry on one line. If there are multiple, then the following lines are indented.AgdaGet the most recent CallSite in a  CallStack, if there is one.Agda CallStack! comprising only the most recent CallSiteAgda Transform a  CallStack by transforming its list of CallSiteAgda Transform a  CallStack by filtering each CallSiteAgdaPops n entries off a  CallStack using  popCallStack.. Note that frozen callstacks are unaffected.!NOba`_^]\[cde Safe-Inferred!!$%&.145789:;gAgda%The unicode replacement character  .Agda&Is a character a surrogate code point.Agda?Map surrogate code points to the unicode replacement character.AgdaTotal function to convert an integer to a character. Maps surrogate code points to the replacement character U+FFFD. Safe-Inferred!!$%&.145789:;i~Agda3Tokenization for environment variable substitution.~Agda~.~Agda $VARIABLE or @${VARIABLE}$.~AgdaOrdinary characters.~AgdaTokenize a string. The ~ is recognized as $HOME% only at the beginning of the string.~AgdaHome directory.Agda&Environment variable substitution map.AgdaInput.AgdaOutput with variables and ~ (home) substituted. Safe-Inferred!!$%&.145789:;j+ Safe-Inferred!!$%&.145789:;sAgdaRepeat a state transition f :: a -> (b, a) with output b while condition cond on the output is true. Return all intermediate results and the final result where cond is False.(Postconditions (when it terminates): (fst (last (iterWhile cond f a)) == False. $all fst (init (interWhile cond f a)).AgdaRepeat something while a condition on some state is true. Return the last state (including the changes of the last transition, even if the condition became false then).AgdaMonadic version of .Agda%A version of the trampoline function.The usual function iterates f :: a -> Maybe a as long as Just{}, is returned, and returns the last value of a upon Nothing.usualTrampoline f = trampolineWhile $ a -> maybe (False,a) (True,) (f a).trampolineWhile is very similar to  repeatWhile, only that it discards the state on which the condition went False;, and returns the last state on which the condition was True.AgdaMonadic version of .AgdaMore general trampoline, which allows some final computation from iteration state a into result type b.AgdaMonadic version of .AgdaIteration to fixed-point.iterateUntil r f a0 iterates endofunction f, starting with a0 , until r( relates its result to its input, i.e., f a r a.9This is the generic pattern behind saturation algorithms.If f is monotone with regard to r , meaning a r b implies f a r f b , and f-chains starting with a09 are finite then iteration is guaranteed to terminate.*A typical instance will work on sets, and r could be set inclusion, and a0 the empty set, and f- the step function of a saturation algorithm.AgdaMonadic version of .Agda n f x applies f to x n times and returns the result.)The applications are calculated strictly.AgdaapplyWhen b f a applies f to a when b.AgdaapplyUnless b f a applies f to a unless b.AgdaMonadic version of  applyWhenAgdaMonadic version of  applyUnless Safe-Inferred!!$%&.145789:;tAgdaSemiring with idempotent ~ == dioidAgdaE.g. +Agdaneutral element of compose , e.g. zero  Safe-Inferred!!$%&.145789:;y Agda?A decoration is a functor that is traversable into any functor.The ~ superclass is given because of the limitations of the Haskell class system.  traverseF actually implies functoriality.Minimal complete definition:  traverseF or  distributeF.Agda traverseF is the defining property.Agda%Decorations commute into any functor.Agda?Composition: pure function after functorial (monadic) function.AgdaThe true pure for loop.  is a misnomer, it should be forA.AgdaInfix version of .Agda#Any decoration is traversable with traverse = traverseF. Just like any ~6 is a functor, so is any decoration, given by just  traverseF , a functor.AgdaAny decoration is a lens. set is a special case of dmap.Agda0A typical decoration is pairing with some stuff.Agda3Decorations compose. (Thus, they form a category.)Agda%The identity functor is a decoration. TU TU9 1 Safe-Inferred!!$%&.145789:;zAgdaShould not be used when  could be used.AgdaShould only be used in let or where.Agda7Unstructured pragma (Andreas, 2017-08-23, issue #2712). Safe-Inferred!!$%&.145789:;}Agda The function  makes every function argument, case and generator pattern, and  binding strict (except for those patterns that are marked as irrefutable, and anything in a  or :). Note that only the outermost patterns are made strict. Safe-Inferred!!$%&.145789:;~AgdaCatch ~s.Agda#Upon exception, the state is reset.Agda+Upon exception, the written output is lost.Agda Alias of ~ for the IO monad. Safe-Inferred!!$%&.145789:;AgdaReturns a close function for the file together with the contents. Safe-Inferred!!$%&.145789:;~Agda=Action to be carried out for copying a directory recursively.~AgdaCreate directory if missing.~AgdaCopy file if changed.AgdacopyDirContent src dest recursively copies directory src onto dest.First, a to-do list of copy actions is created. Then, the to-do list is carried out.This avoids copying files we have just created again, which can happen if src and dest( are not disjoint. (See issue #2705.)~AgdaPerform scheduled ~.~AgdacopyDirContentDryRun src dest; creates a to-do list for recursively copying directory src onto dest.~AgdacopyIfChanged src dst makes sure that dst' exists and has the same content as dst. Safe-Inferred!!$%&.145789:;AgdaCreates a temporary file, writes some stuff, and returns the filepath  Safe-Inferred!!$%&.145789:;~AgdaConverts many character sequences which may be interpreted as line or paragraph separators into 'n'.Note that 'rn' is assumed to have already been converted to 'n'.AgdaReads a UTF8-encoded text file and converts many character sequences which may be interpreted as line or paragraph separators into 'n'.AgdaReads a UTF8-encoded text file and converts many character sequences which may be interpreted as line or paragraph separators into 'n'.AgdaWrites a UTF8-encoded text file. The native convention for line endings is used.AgdaWrites a UTF8-encoded text file. The native convention for line endings is used.! Safe-Inferred!!$%&.145789:;-AgdaRead ~+, modify it strictly, and return old value. ~~~~~~~~~~" Safe-Inferred!!$%&.145789:;q AgdaMonads in which we can catch an "impossible" error, if possible.Agda Catch any  exception.Agda Catch only # exceptions selected by the filter.Agda Version of , with argument order suiting short handlers.Agda Version of , with argument order suiting short handlers.Agda"Impossible" errors, annotated with a file name and a line number corresponding to the source code location of the error.Agda7We reached a program point which should be unreachable.Agda Impossible with a different error message. Used when we reach a program point which can in principle be reached, but not for a certain run.AgdaWe reached a program point without all the required primitives or BUILTIN to proceed forward. (ImpMissingDefinitions neededDefs forThisAgdaAbort by throwing an "impossible" error. You should not use this function directly. Instead use  IMPOSSIBLEAgda Throw an  Impossible* error reporting the *caller's* call site.Agda Throw an  Unreachable error reporting the *caller's* call site. Note that this call to "withFileAndLine" will be filtered out due its filter on the srcLocModule.  # Safe-Inferred!!$%&.145789:;AgdatoImpossible e extracts the  Impossible value raised via  IMPOSSIBLE to create the element e of type Empty. It proceeds by evaluating e to weak head normal form and catching the exception. We are forced to wrap things in a Maybe because of catchImpossible's type.AgdaValues of type  are not forced, because ' is used as a constructor argument in .$ Safe-Inferred!!$%&.145789:;AgdaA set with duplicates. Faithfully stores elements which are equal with regard to (==).Agda%The list contains all occurrences of a (not just the duplicates!). Hence, the invariant: the list is never empty.AgdaIs the bag empty?Agda7Number of elements in the bag. Duplicates count. O(n).Agda (bag ! a) finds all elements equal to a(. O(log n). Total function, returns [] if none are.Agda O(log n).Agda O(log n).AgdaReturn the multiplicity of the given element. O(log n + count _ _).AgdaO(1)AgdaO(1)Agda "insert a b = union b (singleton a)Agda !fromList = unions . map singletonAgda:Returns the elements of the bag, grouped by equality (==).Agda!Returns the bag, with duplicates.Agda#Returns the bag without duplicates.Agda!Returns the bag, with duplicates.% Safe-Inferred!!$%&.145789:;\AgdaAgsy's meta variables.a the type of the metavariable (what it can be instantiated with). blk= the search control information (e.g. the scope of the meta).AgdaMaybe an instantiation (refinement). It is usually shallow, i.e., just one construct(or) with arguments again being metas.AgdaDoes this meta block a principal constraint (i.e., a type-checking constraint).Agda:List of observers, i.e., constraints blocked by this meta.Agda4Used for experiments with independence of subproofs.Agda Experimental.AgdaResult of type-checking.AgdaSuccess.AgdaDefinite failure.Agda Experimental.Agda$Parallel conjunction of constraints.AgdaExperimental, related to . First arg is sidecondition.AgdaForking proof on something that is not part of the term language. E.g. whether a term will reduce or not.Agda Obsolete.AgdaTrav instance a with block type blk& Safe-Inferred"!$%&.145789:; AgdaRepresents a set of integers. Invariants: - All cannot be the argument to ~ or ~ - at most one  IntsBelow - at most one  IntsAbove - if `Below lo` and `Below hi`, then `lo < hi` - if `Below lo .. (Some xs)` then `all (> lo) xs` - if `Above hi .. (Some xs)` then `all (< hi - 1) xs`Agda MembershipAgdaAll integers `< n`AgdaAll integers `>= n`AgdaA single integer.~AgdaFrom a list of integers.Agda No integers.Agda All integers.Agda'If finite, return the list of elements.Agda Invariant.  ' Safe-Inferred!!$%&.145789:; AgdaVan Laarhoven style homogeneous lenses. Mnemoic: "Lens inner outer".AgdaGet inner part i of structure o as designated by  Lens' i o.AgdaSet inner part i of structure o as designated by  Lens' i o.AgdaModify inner part i of structure o using a function i -> i.Agda8Focus on a part of the state for a stateful computation.AgdaRead a part of the state.AgdaWrite a part of the state.AgdaModify a part of the state.Agda'Modify a part of the state monadically.Agda?Modify a part of the state monadically, and return some result.Agda#Modify a part of the state locally.Agda Ask for part of read-only state.Agda/Modify a part of the state in a subcomputation.84444( Safe-Inferred&!$%&()./0145789:; Agda An index into a type-level list.Agda4Lists indexed by a type-level list. A value of type All p [xA..xA]% is a sequence of values of types p xA, .., p xA.Agda&Existential wrapper for indexed types.AgdaUnpacking a wrapped value.Agda/Constructing an indexed list from a plain list.Agda/Turning an indexed list back into a plain list.Agda!Indices are just natural numbers.AgdaMapping over an indexed list.Agda>If you have an index you can get a lens for the given element.Agda)Looking up an element in an indexed list.Agda!All indices into an indexed list.) Safe-Inferred!!$%&.145789:;AgdaTokenising the input (makes  cleaner)Agda*Options for Auto, default value and lenses$$* Safe-Inferred!!$%&.145789:;KAgda(View source:) This is how you implement a lens for a record field.+ Safe-Inferred"!$%&.145789:;^Agda;Update monadically the value at one position (must exist!).Agda Wrapper for  for convenience.AgdaFilter a map based on the keys., Safe-Inferred!!$%&.145789:;/AgdaRetain object when tag is ~.Agda unionWith for collections of size <= 1.Agda unionsWith for collections of size <= 1.Agda Unzipping a list of length <= 1.AgdaFiltering a singleton list. filterMaybe p a = ~ (~ p [a])Agda Version of ~" with different argument ordering.Agda Version of ~ with different argument ordering. Often, we want to case on a ~%, do something interesting in the ~( case, but only a default action in the ~* case. Then, the argument ordering of  caseMaybe is preferable. $caseMaybe m d f = flip (maybe d) m fAgda with flipped branches.AgdaMonadic version of ~.AgdaMonadic version of ~.AgdaMonadic version of . That is, $ with a different argument ordering.Agda with flipped branches.AgdaA more telling name for  for the ~ collection type. Or:  without the ~ case.Agda without the ~ case.Agda without the ~ case.Agda without the ~ case.AgdaLazy version of allJust  . sequence. (allJust = mapM for the Maybe/ monad.) Only executes monadic effect while isJust.AgdaLift a maybe to an Alternative.~~~~~~~~~~~~- Safe-Inferred!!$%&.145789:;sAgda"Simple, non-reentrant memoisation.AgdaRecursive memoisation, second argument is the value you get on recursive calls.. Safe-Inferred"!$%&.145789:;Agda/Maximum of on-negative (small) natural numbers./ Safe-Inferred!!$%&.145789:;Agda Satisfying null empty == True.AgdaA ~ is ' when it corresponds to the empty list.  0 Safe-Inferred"!$%&.145789:;QAgda Analogous to  in  Data.Maybe.Agda Analogous to  in  Data.Maybe.Agda Analogous to  in  Data.Maybe.Agda Analogous to  in  Data.Maybe.Agda unionWith for collections of size <= 1.Agda Unzipping a list of length <= 1.AgdaFiltering a singleton list. filterMaybe p a =  (~ p [a])Agda Version of " with different argument ordering.Agda Version of  with different argument ordering. Often, we want to case on a %, do something interesting in the ( case, but only a default action in the * case. Then, the argument ordering of  caseMaybe is preferable. (caseMaybe m err f = flip (maybe err) m fAgdaMonadic version of .AgdaMonadic version of .AgdaMonadic version of . That is, $ with a different argument ordering.Agda with flipped branches.AgdaA more telling name for  for the  collection type. Or:  without the  case.Agda without the  case.AgdaNote that strict Maybe is an ~ only modulo strictness. The laws only hold in the strict semantics. Eg. pure f  * pure _|_ = _|_#, but according to the laws for ~ it should be  pure (f _|_)3. We ignore this issue here, it applies also to ~ and ~.1 Safe-Inferred"!$%&.145789:;zAgdaInclusion comparison wrapper.AgdaPointwise comparison wrapper.AgdaDecidable partial orderings.Agda6The result of comparing two things (of the same type).Agda Less than.AgdaLess or equal than.AgdaEqualAgdaGreater or equal.Agda Greater than.AgdaNo information (incomparable).Agda8Comparing the information content of two elements of '. More precise information is smaller.Includes equality: x  x == True.Agda Opposites.related a po b iff related b (oppPO po) a.AgdaCombining two pieces of information (picking the least information). Used for the dominance ordering on tuples.orPO1 is associative, commutative, and idempotent. orPO has dominant element POAny, but no neutral element.AgdaChains (transitivity)  x R y S z.seqPO1 is associative, commutative, and idempotent. seqPO has dominant element POAny and neutral element (unit) POEQ.AgdaEmbed ~.Agda%Represent a non-empty disjunction of ~s as .AgdaA ! information is a disjunction of ~ informations.AgdaAny ~ is a .Agda+Are two elements related in a specific way? related a o b holds iff comparable a b is contained in o.Agda1Partial ordering forms a monoid under sequencing.Agda.Less is ``less general'' (i.e., more precise).Agda&Pointwise partial ordering for tuples.related (x1,x2) o (y1,y2) iff related x1 o x2 and related y1 o y2.Agda$Partial ordering for disjoint sums: Left _ and Right _ are unrelated.Agda~ and ~ _ are unrelated.Partial ordering for Maybe a is the same as for  Either () a.Agda4The pointwise ordering for lists of the same length.There are other partial orderings for lists, e.g., prefix, sublist, subset, lexicographic, simultaneous order.Agda(Sets are partially ordered by inclusion.AgdaSublist for ordered lists.2 Safe-Inferred"!$%&.145789:;Agda?Completing POMonoids with inverses to form a Galois connection.Law: composition and inverse composition form a Galois connection. & related (inverseCompose p x) POLE y  == related x POLE (p <> y) AgdaPartially ordered monoid."Law: composition must be monotone.  related x POLE x' && related y POLE y' ==> related (x <> y) POLE (x' <> y') AgdaPartially ordered semigroup."Law: composition must be monotone.  related x POLE x' && related y POLE y' ==> related (x <> y) POLE (x' <> y') AgdahasLeftAdjoint x checks whether  x^-1 := x  mempty is such that x  y == x^-1 <> y for any y.3 Safe-Inferred!!$%&.145789:;,AgdaIf f a contains many copies of a they will all be the same pointer in the result. If the function is well-behaved (i.e. preserves the implicit equivalence, this shouldn't matter).4 Safe-Inferred!!$%&.145789:;<AgdaStar semirings ( 5https://en.wikipedia.org/wiki/Semiring#Star_semirings).Agda Semirings ( &https://en.wikipedia.org/wiki/Semiring). Safe-Inferred!!$%&.145789:;į5 Safe-Inferred!!$%&.145789:;źAgda Overloaded  singleton constructor for collections.AgdaA create-only possibly empty collection is a monoid with the possibility to inject elements.6 Safe-Inferred"!$%&.145789:;[AgdaCharacteristic identifiers.AgdaGiven a function f :: a -> NonEmpty C6 which returns a non-empty list of characteristics C of a, partition a list of as into groups such that each element in a group shares at least one characteristic with at least one other element of the group.AgdaPartition a list of a5s paired with a non-empty list of characteristics C into groups such that each element in a group shares at least one characteristic with at least one other element of the group. Safe-Inferred!!$%&.145789:;~AgdaLet n be the size of type a.Agda Time O(n)!Agda Time O(1).Agdanot . member a . Time O(1).Agda Time O(n).AgdaThe empty set. Time O(n).AgdaThe full set. Time O(n).AgdaA singleton set. Time O(n).Agda Time O(n).Agda Time O(n).Agda Time O(n).Agda Time O(n).Agda Time O(n).Agda Time O(n).Agda Time O(n).Agda Time O(n).Agda Time O(n).Agda Time O(n).Agda Time O(n).Agda Time O(n).Agda Time O(n).Agda Time O(n).Agda Time O(n).~AgdaTime O(n). Assumes Bool-vector of length n.~AgdaTime O(n). Produces Bool-vector of length n.~AgdaTime O(n). Produces Bool-vector of length n.~AgdaTime O(n). Bulk insert/delete.7 Safe-Inferred!!$%&.145789:;[ Agda&Classification of identifier variants.AgdaIdentifier ends in Integer many primes.AgdaIdentifier ends in number Integer (ordinary digits).AgdaIdentifier ends in number Integer (subscript digits).Agda'Is the character one of the subscripts 'A'-'A'?Agda Converts '0'-'9' to 'A'-'A'-Precondition: The digit needs to be in range.Agda Converts 'A'-'A' to '0'-'9'.-Precondition: The digit needs to be in range.AgdaIncrease the suffix by one.Agda Parse suffix.Agda Print suffix.  8 Safe-Inferred!!$%&.145789:;AgdaDisjoint sum of three.AgdaEnum type with 3 elements.AgdaPartition a list into 3 groups.)Preserves the relative order or elements.AgdaPartition a list into 3 groups.)Preserves the relative order or elements.  9 Safe-Inferred!!$%&.145789:;ևAgdaFinite map from [k] to v.With the strict ~ type,  is also strict in v.~Agda"Helper function used to implement  and .AgdaSingleton trie.AgdaeveryPrefix k v! is a trie where every prefix of k (including k itself) is mapped to v.AgdaLeft biased union.#union = unionWith ( new old -> new).Agda/Pointwise union with merge function for values.Agda.Insert. Overwrites existing value if present. %insert = insertWith ( new old -> new)Agda6Insert with function merging new value with old value.Agda.Delete value at key, but leave subtree intact.Agda*Adjust value at key, leave subtree intact.AgdaConvert to ascending list.AgdaConvert to ascending list.AgdaConvert to list where nodes at the same level are ordered according to the given ordering.AgdaCreate new values based on the entire subtrie. Almost, but not quite comonad extend.Agda8Returns the value associated with the given key, if any.Agda%Is the given key present in the trie?Agda&Collect all values along a given path.Agda(Get the subtrie rooted at the given key.AgdaFilter a trie.Agda Key lens.Agda Empty trie.  Safe-Inferred!!$%&.145789:;AgdaBifunctoriality for pairs.Agda mapFst f = f -*- idAgda mapSnd g = id -*- gAgdaLifted pairing.AgdaMonadic version of .AgdaMonadic .AgdaMonadic .SS23: Safe-Inferred!!$%&.145789:;Agda$Internal state for stripping suffix.AgdaError.Agda8"Negative string" to remove from end. List may be empty.Agda+"Positive string" (result). Non-empty list.AgdaAppend a single element at the end. Time: O(length); use only on small lists.Agda5Case distinction for lists, with list first. O(1).Cf. /.Agda5Case distinction for lists, with list first. O(1).Cf. /.Agda4Case distinction for lists, with list last. O(1).AgdaHead function (safe). Returns a default value on empty lists. O(1). >headWithDefault 42 [] = 42 headWithDefault 42 [1,2,3] = 1AgdaTail function (safe). O(1).AgdaTail function (safe). Returns a default list on empty lists. O(1).AgdaLast element (safe). O(n).AgdaLast element (safe). Returns a default list on empty lists. O(n).Agda3Last element of non-empty list (safe). O(n). last1 a as = last (a : as)Agda"Last two elements (safe). O(n).AgdaOpposite of cons (:), safe. O(1).AgdaMaybe cons. O(1). "mcons ma as = maybeToList ma ++ asAgda and  in one go, safe. O(n).Agda and & of non-empty list, safe. O(n). *initLast1 a as = (init (a:as), last (a:as)Agda& of non-empty list, safe. O(n). init1 a as = init (a:as)Agdainit, safe. O(n).Agdainit, safe. O(n).Agda4Lookup function (partially safe). O(min n index).AgdaLookup function with default value for index out of range. O(min n index).The name is chosen akin to .AgdaFind an element satisfying a predicate and return it with its index. O(n) in the worst case, e.g. findWithIndex f xs = Nothing.%TODO: more efficient implementation!?AgdaA generalised variant of  elemIndex. O(n).AgdadownFrom n = [n-1,..1,0] . O(n).Agda:Update the first element of a list, if it exists. O(1).Agda9Update the last element of a list, if it exists. O(n).Agda/Update nth element of a list, if it exists. O(min index n). Precondition: the index is >= 0.Agda#splitExactlyAt n xs = Just (ys, zs) iff  xs = ys ++ zs and genericLength ys = n.Agda*Drop from the end of a list. O(length). &dropEnd n = reverse . drop n . reverseForces the whole list even for n==0.AgdaSplit off the largest suffix whose elements satisfy a predicate. O(n).spanEnd p xs = (ys, zs) where  xs = ys ++ zs and all p zs and #maybe True (not . p) (lastMaybe yz).AgdaBreaks a list just after1 an element satisfying the predicate is found. breakAfter1 even 1 [3,5,2,4,7,8]([1,3,5,2],[4,7,8])AgdaBreaks a list just after1 an element satisfying the predicate is found.breakAfter even [1,3,5,2,4,7,8]([1,3,5,2],[4,7,8])AgdaA generalized version of  takeWhile . (Cf. mapMaybe vs. filter#). @O(length . takeWhileJust f)."takeWhileJust f = fst . spanJust f.AgdaA generalized version of span. O(length . fst . spanJust f).AgdaPartition a list into ~s and ~ s. O(n). partitionMaybe f = partitionEithers . map ( a -> maybe (Left a) Right (f a))Note: ~ f = snd . partitionMaybe f.AgdaLike ~, but additionally return the last partition of the list where the predicate is False everywhere. O(n).AgdaLike ~, but additionally return the last partition of the list where the function always returns Nothing . O(n).AgdaSublist relation.Agda7All ways of removing one element from a list. O(n).Agda6Compute the common prefix of two lists. O(min n m).AgdaDrops from both lists simultaneously until one list is empty. O(min n m).AgdaCheck if a list has a given prefix. If so, return the list minus the prefix. O(length prefix).Agda4Compute the common suffix of two lists. O(n + m).AgdastripSuffix suf xs = Just pre iff xs = pre ++ suf. O(n).Agda&stripReversedSuffix rsuf xs = Just pre iff xs = pre ++ reverse suf . O(n).Agda"Find out whether the first string xs7 has a suffix that is a prefix of the second string ys. So, basically, find the overlap where the strings can be glued together. Returns the index where the overlap starts and the length of the overlap. The length of the overlap plus the index is the length of the first string. Note that in the worst case, the empty overlap  (length xs,0) is returned.Agda f = groupBy (( ) `on` f)   ( `on` f). O(n log n).Agda A variant of  which applies the predicate to consecutive pairs. O(n). DEPRECATED in favor of .AgdaSplit a list into sublists. Generalisation of the prelude function words . O(n). words xs == wordsBy isSpace xsAgda2Chop up a list in chunks of a given length. O(n).AgdaChop a list at the positions when the predicate holds. Contrary to , consecutive separator elements will result in an empty segment in the result. O(n). *intercalate [x] (chopWhen (== x) xs) == xsAgdaCheck membership for the same list often. Use partially applied to create membership predicate hasElem xs :: a -> Bool. First time:  O(n log n) in the worst case.Subsequently: O(log n).Specification: hasElem xs == ( xs).Agda&Check whether a list is sorted. O(n).Assumes that the ~% instance implements a partial order.AgdaCheck whether all elements in a list are distinct from each other. Assumes that the - instance stands for an equivalence relation.O(n) in the worst case distinct xs == True.AgdaAn optimised version of . O(n log n)./Precondition: The list's length must fit in an ~.AgdaReturns an (arbitrary) representative for each list element that occurs more than once. O(n log n).AgdaRemove the first representative for each list element. Thus, returns all duplicate copies. O(n log n).&allDuplicates xs == sort $ xs \ nub xs.AgdaPartition a list into first and later occurrences of elements (modulo some quotient given by a representation function).Time: O(n log n).Specification: nubAndDuplicatesOn f xs = (ys, xs List.\\ ys) where ys = nubOn f xsAgdaEfficient variant of nubBy for lists, using a set to store already seen elements. O(n log n)Specification: )nubOn f xs == 'nubBy' ((==) `'on'` f) xs.AgdaEfficient variant of nubBy for finite lists. O(n log n). uniqOn f == 'List.sortBy' (compare `'on'` f) . 'nubBy' ((==) `'on'` f),If there are several elements with the same f--representative, the first of these is kept.AgdaChecks if all the elements in the list are equal. Assumes that the 6 instance stands for an equivalence relation. O(n).AgdaNon-efficient, monadic nub . O(n).Agda5Requires both lists to have the same length. O(n). Otherwise, Nothing is returned.AgdaLike  but keep the rest of the second list as-is (in case the second list is longer). O(n).  zipWithKeepRest f as bs == zipWith f as bs ++ drop (length as) bs AgdaImplemented using tree recursion, don't run me at home! O(3^(min n m)).Agda*Implemented using dynamic programming and  Data.Array . O(n*m).AgdaThe list after the split point.Agda The list before the split point. Safe-Inferred"!$%&.145789:;Agda%Return the last element and the rest.AgdaBuild a list with one element.More precise type for snoc.AgdaMore precise type for :. A variant of : which applies the predicate to consecutive pairs. O(n).AgdaBreaks a list just after1 an element satisfying the predicate is found.breakAfter even [1,3,5,2,4,7,8]([1,3,5,2],[4,7,8])Agda(Concatenate one or more non-empty lists.AgdaLike 8. Duplicates in the first list are not removed. O(nm).AgdaChecks if all the elements in the list are equal. Assumes that the 6 instance stands for an equivalence relation. O(n).AgdaLike ~.AgdaLike :.AgdaLike .AgdaLike .AgdaLike .AgdaNon-efficient, monadic % . O(n).AgdaLike .AgdaLike .  !"#$%&'()*+,-./0123456789:;<=>?@ABC  !"#$%&'()*+,-./0123456789:;<=>?@ABC; Safe-Inferred!!$%&.145789:; Agda adds double quotes around the string, replaces newline characters with n, and escapes double quotes and backslashes within the string. This is different from the behaviour of : >  $  "\x2200" "\8704" >  $  "\x2200" "D" (The code examples above have been tested using version 4.2.0.0 of the base library.)AgdaTurns the string into a Haskell string literal, avoiding escape codes.Agda$Adds hyphens around the given stringputStrLn $ delimiter "Title"<@@@@ Title @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@Agda1Adds a final newline if there is not already one.Agda-Indents every line the given number of steps.Agda6Show a number using comma to separate powers of 1,000.AgdaRemove leading whitespace.AgdaRemove trailing whitespace.Agda'Remove leading and trailing whitesapce.  < Safe-Inferred!!$%&.145789:;CAgdaThing decorated with its size. The thing should fit into main memory, thus, the size is an Int.Agda,The size of a collection (i.e., its length).AgdaCache the size of an object.AgdaReturn the cached size.= Safe-Inferred!!$%&.145789:;Agda%Things that support delayed dropping.Agda)Delayed dropping which allows undropping.Agda&Non-negative number of things to drop.AgdaWhere to drop from.Agda3Invert a Permutation on a partial finite int map. inversePermute perm f = f' such that permute perm f' = f!Example, with map represented as  [Maybe a]:  f = [Nothing, Just a, Just b ] perm = Perm 4 [3,0,2] f' = [ Just a , Nothing , Just b , Nothing ]  Zipping perm with f gives  [(0,a),(2,b)], after compression with  catMaybes. This is an IntMap9 which can easily written out into a substitution again.AgdaPartial permutations. Examples:)permute [1,2,0] [x0,x1,x2] = [x1,x2,x0] (proper permutation).&permute [1,0] [x0,x1,x2] = [x1,x0] (partial permuation).,permute [1,0,1,2] [x0,x1,x2] = [x1,x0,x1,x2]- (not a permutation because not invertible).Agda typing would be: 9Perm : {m : Nat}(n : Nat) -> Vec (Fin n) m -> Permutation m is the  of the permutation.Agda'permute [1,2,0] [x0,x1,x2] = [x1,x2,x0] More precisely, permute indices list = sublist , generates sublist from list1 by picking the elements of list as indicated by indices. *permute [1,3,0] [x0,x1,x2,x3] = [x1,x3,x0]Agda typing: ,permute (Perm {m} n is) : Vec A m -> Vec A nAgdaIdentity permutation.Agda"Restrict a permutation to work on n elements, discarding picks >=n.Agda9Pick the elements that are not picked by the permutation.AgdaliftP k takes a  Perm {m} n to a Perm {m+k} (n+k). Analogous to ?, but Permutations operate on de Bruijn LEVELS, not indices.Agda 2permute (compose p1 p2) == permute p1 . permute p2Agda invertP err p is the inverse of p) where defined, otherwise defaults to err. composeP p (invertP err p) == pAgdaTurn a possible non-surjective permutation into a surjective permutation. Agda ?permute (reverseP p) xs == reverse $ permute p $ reverse xs Example:  permute (reverseP (Perm 4 [1,3,0])) [x0,x1,x2,x3] == permute (Perm 4 $ map (3-) [0,3,1]) [x0,x1,x2,x3] == permute (Perm 4 [3,0,2]) [x0,x1,x2,x3] == [x3,x0,x2] == reverse [x2,x0,x3] == reverse $ permute (Perm 4 [1,3,0]) [x3,x2,x1,x0] == reverse $ permute (Perm 4 [1,3,0]) $ reverse [x0,x1,x2,x3] With reverseP, you can convert a permutation on de Bruijn indices to one on de Bruijn levels, and vice versa. Agda8permPicks (flipP p) = permute p (downFrom (permRange p)) or permute (flipP (Perm n xs)) [0..n-1] = permute (Perm n xs) (downFrom n)Can be use to turn a permutation from (de Bruijn) levels to levels to one from levels to indices.See . Agda expandP i n  in the domain of  replace the ith element by n elements. AgdaStable topologic sort. The first argument decides whether its first argument is an immediate parent to its second argument.AgdaPerform the dropping.Agda Drop more.AgdaPick up dropped stuff.   Safe-Inferred!!$%&.145789:; AgdaLists of length D2. Agda Safe. O(1). Agda Safe. O(1). Agda Safe. O(n). Agda Safe. O(1). Agda Safe. O(1). Agda Safe. O(1). AgdaUnsafe! > Safe-Inferred"!$%&.145789:; AgdaDenotational equality for floating point numbers, checks bitwise equality.NOTE: Denotational equality distinguishes NaNs, so its results may vary depending on the architecture and compilation flags. Unfortunately, this is a problem with floating-point numbers in general. AgdaI guess "denotational orderings" are now a thing? The point is that we need an Ord instance which provides a total ordering, and is consistent with the denotational equality.NOTE: The ordering induced via  * is total, and is consistent with  . However, it is *deeply* unintuitive. For one, it considers all negative numbers to be larger than positive numbers. AgdaReturn Just x if it's a finite number, otherwise return Nothing. AgdaRemove suffix .0$ from printed floating point number. Agda$Decode a Double to an integer ratio. Agda$Encode an integer ratio as a double. AgdaDecode a Double to its mantissa and its exponent, normalised such that the mantissa is the smallest possible number without loss of accuracy. AgdaChecks whether or not the Double is within a safe range of operation.AgdaThe smallest representable mantissa. Simultaneously, the smallest integer which can be represented as a Double without loss of precision.AgdaThe largest representable mantissa. Simultaneously, the largest integer which can be represented as a Double without loss of precision.Agda#The largest representable exponent.Agda$The smallest representable exponent. Agda.Encode a mantissa and an exponent as a Double.+ +  Safe-Inferred!!$%&.145789:; AgdaWhile - is for rendering data in Haskell syntax,   is for displaying data to the world, i.e., the user and the environment.Atomic data has no inner document structure, so just implement   as pretty a = text $ ... a .... AgdaUse instead of  when printing to world. Agda1Separate, but only if both separees are not null. Agda+Comma separated list, without the brackets. AgdaPretty print a set. Agda!Pretty print an association list. Agda"Pretty print a single association. AgdaApply  to s if boolean is true. AgdaOnly wrap in parens if not  Agdaalign max rows lays out the elements of rows in two columns, with the second components aligned. The alignment column of the second components is at most max2 characters to the right of the left-most column.Precondition: max > 0. Agda?Handles strings with newlines properly (preserving indentation) Agda a  ? b = hang a 2 b Agda pshow = text . show AgdaUsed for with-like  telescopesstuvwxyz{|}~ stuvwxyz{|}~ 6? Safe-Inferred!!$%&.145789:;  Agda"CPU time in pico (10^-12) seconds. Agda Timestamps. AgdaThe current time. AgdaMeasure the time of a computation. Of course, does not work with exceptions. Agda(Print CPU time in milli (10^-3) seconds.  @ Safe-Inferred!!$%&.145789:;*AgdaThe extended parser type computes one top-level document, plus one document per encountered memoisation key.~ is used to mark that a given memoisation key has been seen, but that no corresponding document has yet been stored. Agda(Documents paired with precedence levels. AgdaAn extended parser type, with some support for printing parsers.AgdaInvariant: If the boolean is ~, then the result must be  something, and if the boolean is , then the result must be  something. AgdaRuns the parser. Agda&Tries to print the parser, or returns , depending on the implementation. This function might not terminate. AgdaParses a token satisfying the given predicate. The computed value is returned. AgdaUses the given function to modify the printed representation (if any) of the given parser. AgdaMemoises the given parser./Every memoised parser must be annotated with a unique key. (Parametrised parsers must use distinct keys for distinct inputs.) AgdaMemoises the given parser, but only if printing, not if parsing./Every memoised parser must be annotated with a unique key. (Parametrised parsers must use distinct keys for distinct inputs.) AgdaThe parser type.The parameters of the type Parser k r tok a have the following meanings: kType used for memoisation keys.rThe type of memoised values. (Yes, all memoised values have to have the same type.)tokThe token type.aThe result type.AgdaMemoised values.AgdaContinuations.AgdaState monad used by the parser.Agda Positions. AgdaUses the given document as the printed representation of the given parser. The document's precedence is taken to be  . Agda.Parses a token satisfying the given predicate. AgdaParses a single token. AgdaParses a given token. AgdaPrecedence of >>=. AgdaPrecedence of  |. AgdaPrecedence of  *. AgdaPrecedence of E and +. AgdaPrecedence of atoms.AgdaA smart constructor.AgdaExtracts the parser.AgdaExtracts the documents.AgdaA helper function.Agda Pretty-prints a memoisation key.AgdaA helper function.   Safe-Inferred!!$%&.145789:;+E Safe-Inferred!!$%&.145789:;+!NOb[\]^_`acde!NOb[\]^_`acdeA Safe-Inferred!!$%&.145789:;1 Agda4The flexibe variables contained in a pice of syntax. Agda2The rigid variables contained in a pice of syntax. Agda)Make offsets non-negative by rounding up. AgdaOffsets + n must be non-negative AgdaExecuting a substitution. AgdaPartial substitution from flexible variables to size expression. Agda*Type of solution wanted for each flexible. Agda,Assigning a polarity to a flexible variable. Agda)What type of solution are we looking for? Agda= 0. AgdaDefault polarity is  . Agda?Returns an error message if we have a contradictory constraint. Agda  acts as ~,   as . Agda Interpret   as relation on  . AgdaAdd offset to size expression. AgdaComparison operator is ordered   <  .7 7 B Safe-Inferred!!$%&.145789:;6 AgdaSimple Emacs Lisp expressions. AgdaAtom. AgdaList. AgdaFormats a response command. Replaces 'n'= with spaces to ensure that each command is a single line. Agda-Writes a response command to standard output.Agda0displayInBuffer buffername append header content displays content (with header header%) in some suitable way in the buffer  buffername. If append is True, then the content is appended to previous content (if any), otherwise any previous content is deleted.Agda$The name of the running info buffer. AgdaClear the running info buffer. AgdaClear the warning buffer AgdaDisplay running information about what the type-checker is up to.  Safe-Inferred!!$%&.145789:;;8 Agda Loop while we have an exception. AgdaMonadic version of $ with a different argument ordering. Agda'Either _ b' is a functor. Agda'Either a' is a functor. Agda is bitraversable. Note: From base >= 4.10.0.0 already present in . Agda Analogue of . Agda Analogue of . Agda Analogue of ,. Agda Analogue of ,. AgdaSafe projection from . 8maybeLeft (Left a) = Just a maybeLeft Right{} = Nothing AgdaSafe projection from .  x) xs) else Nothing Agda)Groups a list into alternating chunks of  and  values AgdaConvert ~ to  e, given an error e for the ~ case. Agda Swap tags  and .PQ  QP  Safe-Inferred!!$%&.145789:;D Agda Binary bind. AgdaMonadic guard. AgdaMonadic if-then-else. Agda ifNotM mc = ifM (not  $ mc) AgdaLazy monadic conjunction. AgdaLazy monadic disjunction. AgdaLazy monadic disjunction with Either> truth values. Returns the last error message if all fail. AgdaLazy monadic disjunction with accumulation of errors in a monoid. Errors are discarded if we succeed. AgdaGeneralized version of 8traverse_ :: Applicative m => (a -> m ()) -> [a] -> m () Executes effects and collects results in left-to-right order. Works best with left-associative monoids.!Note that there is an alternative !mapM' f t = foldr mappend mempty  $ mapM f tthat collects results in right-to-left order (effects still left-to-right). It might be preferable for right associative monoids. AgdaGeneralized version of 3for_ :: Applicative m => [a] -> (a -> m ()) -> m () AgdaA monadic version of ~ :: (a -> Maybe b) -> [a] -> [b]. Agda A version of  ' with a computation for the input list. AgdaThe for version of  . AgdaThe for version of  . AgdaA monadic version of  :: (a -> Bool) -> [a] -> [a]. AgdaA monadic version of  dropWhileEnd :: (a -> Bool) -> [a] -> m [a]:. Effects happen starting at the end of the list until p becomes false. AgdaA `monadic' version of @ partition# :: (a -> Bool) -> [a] -> ([a],[a]) Agda Translates ~ to X. AgdaGeneralises the ~& function from lists to an arbitrary X. Agda"Branch over elements of a monadic ~ data structure. AgdaFinally for the Error class. Errors in the finally part take precedence over prior errors. AgdaTry a computation, return ~ if an Error occurs. Agda1Run a command, catch the exception and return it. AgdaLike -, but raise given error when condition fails. Agda;Bracket without failure. Typically used to preserve state. Agda Restore state after computation. AgdaAcquires resource. Run first.AgdaReleases resource. Run last.Agda Computes result. Run in-between.,YKTXWVZ , ZKXWVTYC Safe-Inferred#!$%&.145789:;I Agda.Lazy monadic computation of a list of results. AgdaBoilerplate function to lift  through the   transformer. Agda Inverse to  . AgdaThe empty lazy list. AgdaConsing a value to a lazy list. AgdaSingleton lazy list. Agda Case distinction over lazy list. Agda+Folding a lazy list, effects left-to-right. AgdaLazy monadic disjunction of lazy monadic list, effects left-to-right AgdaLazy monadic conjunction of lazy monadic list, effects left-to-right Agda8Force all values in the lazy list, effects left-to-right AgdaThe join operation of the ListT m monad. AgdaWe can `run' a computation of a   as it is monadic itself. Agda Monadic cons. AgdaMonadic singleton. Agda Extending a monadic function to  . Agda!Alternative implementation using  . Agda Change from one monad to another  D Safe-Inferred"!$%&.145789:;N5 Agda%Paths which are known to be absolute.Note that the  and ~ instances do not check if different paths point to the same files or directories. Agda Extract the   to be used as . Agda Constructs  s.2Precondition: The path must be absolute and valid. AgdaMakes the path absolute.This function may raise an __IMPOSSIBLE__ error if " does not return an absolute path. Agda!Resolve symlinks etc. Preserves  . AgdaTries to establish if the two file paths point to the same file (or directory). AgdaCase-sensitive  for Windows.This is case-sensitive only on the file name part, not on the directory part. (Ideally, path components coming from module name components should be checked case-sensitively and the other path components should be checked case insensitively.) AgdaTrue if the first file is newer than the second file. If a file doesn't exist it is considered to be infinitely old. E Safe-Inferred!!$%&.145789:;O AgdaHashes a piece of . Agda-Hashing a module name for unique identifiers.  F Safe-Inferred!!$%&.145789:;T Agda'Monad with access to benchmarking data. AgdaWe need to be able to terminate benchmarking in case of an exception. AgdaBenchmark structure is a trie, mapping accounts (phases and subphases) to CPU time spent on their performance. AgdaAre we benchmarking at all? Agda!What are we billing to currently? Agda/The accounts and their accumulated timing bill. Agda3Record when we started billing the current account. Agda(Account we can bill computation time to. AgdaSemantic editor combinator. AgdaSemantic editor combinator. AgdaSemantic editor combinator. Agda"Add to specified CPU time account. AgdaTurn benchmarking on/off. AgdaBill current account with time up to now. Switch to new account. Return old account (if any). Agda.Resets the account and the timing information. AgdaBill a computation to a specific account. Works even if the computation is aborted by an exception. Agda;Bill a CPS function to an account. Can't handle exceptions. Agda.Bill a pure computation to a specific account. Agda2Print benchmark as three-column table with totals. Agda$Initial benchmark structure (empty). AgdaMaybe new account.AgdaMaybe old account.  G Safe-Inferred!!$%&.145789:;g AgdaFinite maps from k to v!, with a way to quickly get from v to k for certain values of type v (those for which   is defined).&Every value of this type must satisfy  . Agda0Partial injections from a type to some tag type.The idea is that  ( should be injective on its domain: if   x =   y = ~ i, then x = y. However, this property does not need to hold globally. The preconditions of the  3 operations below specify for which sets of values   must be injective. AgdaChecks if the function   is injective for the values in the given list for which the function is defined. AgdaThe invariant for  . AgdaLookup. O(log n). AgdaInverse lookup. O(log n). AgdaSingleton map. O(1). Agda0Insertion. Overwrites existing values. O(log n).Precondition: See  . AgdaThe precondition for   k v m: If v has a   (  v D ~), then m must not contain any mapping k' C v' for which k D k' and   v =   v'. AgdaModifies the value at the given position, if any. If the function returns ~&, then the value is removed. O(log n).The precondition for   f k m is that, if the value v is inserted into m, and   v% is defined, then no key other than k may map to a value v' for which   v' =   v. AgdaModifies the value at the given position, if any. If the function returns ~&, then the value is removed. O(log n).Precondition: See  . AgdaThe precondition for   f k m is that, if the value v is inserted into m, and   v% is defined, then no key other than k may map to a value v' for which   v' =   v. AgdaModifies the value at the given position, if any. If the function returns ~&, then the value is removed. O(log n).Precondition: See  . AgdaThe precondition for   f k m is that, if the value v is inserted into m, and   v% is defined, then no key other than k may map to a value v' for which   v' =   v. Agda;Modifies the value at the given position, if any. O(log n).Precondition: See  . AgdaThe precondition for   f k m is that, if the value v is inserted into m, and   v% is defined, then no key other than k may map to a value v' for which   v' =   v. AgdaInserts a binding into the map. If a binding for the key already exists, then the value obtained by applying the function to the key, the new value and the old value is inserted, and the old value is returned.Precondition: See  . AgdaThe precondition for   f k v m is that, if the value v' is inserted into m, and   v'% is defined, then no key other than k may map to a value v'' for which   v'' =   v'. AgdaChanges all the values using the given function, which is also given access to keys. O(n log n).Precondition: See  . AgdaThe precondition for   f m!: For any two distinct mappings kA C vA, kA C vA in m for which the tags of f kA vA and f kA vA are defined the values of f must be distinct (f kA vA D f kA vA). Furthermore   must be injective for { f k v | (k, v) D m }. AgdaChanges all the values using the given function, which is also given access to keys. O(n).Precondition: See  ". Note that tags must not change. AgdaThe precondition for   f m is that, if m maps k to v, then   (f k v) ==   v. Agda0Left-biased union. For the time complexity, see .Precondition: See  . AgdaConversion from lists of pairs. Later entries take precedence over earlier ones. O(n log n).Precondition: See  . AgdaConversion to lists of pairs, with the keys in ascending order. O(n). Agda#The keys, in ascending order. O(n). Agda>The values, ordered according to the corresponding keys. O(n). AgdaConversion from two lists that contain distinct keys/tags, with the keys/tags in ascending order. O(n).Precondition: See  . AgdaGenerates input suitable for  . O(n).% % H Safe-Inferred!!$%&.145789:;~s8 Agda=Killing the range of an object sets all range information to  . Agda;If it is also possible to set the range, this is the class.Instances should satisfy   (  r x) == r. Agda5Things that have a range are instances of this class. Agda1Wrapper to indicate that range should be printed. AgdaA range is a file name, plus a sequence of intervals, assumed to point to the given file. The intervals should be consecutive and separated.1Note the invariant which ranges have to satisfy:  . AgdaAn interval. The iEnd* position is not included in the interval.4Note the invariant which intervals have to satisfy:  . Agda Represents a point in the input.If two positions have the same   and   components, then the final two components should be the same as well, but since this can be hard to enforce the program should not rely too much on the last two components; they are mainly there to improve error messages for the user.4Note the invariant which positions have to satisfy:  . AgdaFile. AgdaPosition, counting from 1. AgdaLine number, counting from 1. AgdaColumn number, counting from 1. Agda Sets the   components of the interval. Agda Gets the   component of the interval. Because of the invariant, they are both the same. Agda6Converts a file name and two positions to an interval. AgdaThe length of an interval. AgdaThe intervals that make up the range. The intervals are consecutive and separated ( ). Agda8Turns a file name plus a list of intervals into a range.Precondition:  . AgdaAre the intervals consecutive and separated, do they all point to the same file, and do they satisfy the interval invariant? AgdaRange invariant. Agda"The file the range is pointing to. Agda%Conflate a range to its right margin. Agda*Remove ranges in keys and values of a map. Agda;The first position in a file: position 1, line 1, column 1. Agda;The first position in a file: position 1, line 1, column 1. Agda$Ranges between two unknown positions Agda?Advance the position by one character. A newline character ('n') moves the position to the first character in the next line. Any other character moves the position to the next column. Agda!Advance the position by a string.  movePosByString = foldl' movePos Agda%Backup the position by one character.(Precondition: The character must not be 'n'. Agda2Converts a file name and two positions to a range. Agda"Converts two positions to a range.;Precondition: The positions have to point to the same file. Agda0Converts a file name and an interval to a range. Agda-Converts a range to an interval, if possible. AgdaConverts a range to an interval, if possible. Note that the information about the source file is lost. Agda?Returns the shortest continuous range containing the given one. Agda0Removes gaps between intervals on the same line. Agda*The initial position in the range, if any. Agda*The initial position in the range, if any. Agda;The position after the final position in the range, if any. Agda;The position after the final position in the range, if any. Agda4Finds the least interval which covers the arguments.8Precondition: The intervals must point to the same file. AgdafuseRanges r r' unions the ranges r and r'.!Meaning it finds the least range r0 that covers r and r'.Precondition: The ranges must point to the same file (or be empty). AgdaPrecondition: The ranges must point to the same file (or be empty). Agda beginningOf r is an empty range (a single, empty interval) positioned at the beginning of r. If r" does not have a beginning, then   is returned. AgdabeginningOfFile r is an empty range (a single, empty interval) at the beginning of r's starting position's file. If there is no such position, then an empty range is returned. Agdax `withRangeOf` y sets the range of x to the range of y. Agda*Interleaves two streams of ranged elementsIt will report the conflicts as a list of conflicting pairs. In case of conflict, the element with the earliest start position is placed first. In case of a tie, the element with the earliest ending position is placed first. If both tie, the element from the first list is placed first. AgdaTo get   #, we need a semigroup instance for  . AgdaPrecondition: The ranges of the tuple elements must point to the same file (or be empty). AgdaPrecondition: The ranges of the tuple elements must point to the same file (or be empty). AgdaPrecondition: The ranges of the tuple elements must point to the same file (or be empty). AgdaPrecondition: The ranges of the tuple elements must point to the same file (or be empty). AgdaPrecondition: The ranges of the tuple elements must point to the same file (or be empty). AgdaPrecondition: The ranges of the tuple elements must point to the same file (or be empty). AgdaPrecondition: The ranges of the list elements must point to the same file (or be empty). AgdaPrecondition: The ranges of the list elements must point to the same file (or be empty). AgdaOverlaps with  KillRange [a]. I Safe-Inferred"!$%&.145789:;(AgdaPart of a NotationAgdaArgument is the position of the hole (with binding) where the binding should occur. First range is the rhs range and second is the binder.Agda+Argument is where the expression should go.Agda"An underscore in binding position.AgdaNotation as provided by the syntax declaration.AgdaRewriteEqn' qn p e represents the rewrite and irrefutable with clauses of the LHS. qn stands for the QName of the auxiliary function generated to implement the feature nm/ is the type of names for pattern variables p is the type of patterns e is the type of expressionsAgda  rewrite eAgda with p <- e in eqAgda!Coverage check? (Default is yes).Agda!Universe check? (Default is yes).Agda#Positivity check? (Default = True).Agda0Termination check? (Default = TerminationCheck).AgdaRun the termination checker.Agda#Skip termination checking (unsafe).AgdaTreat as non-terminating.Agda/Treat as terminating (unsafe). Same effect as .Agda2Skip termination checking but use measure instead.AgdaRename from this name.Agda#To this one. Must be same kind as .AgdaNew fixity of  (optional).AgdaThe range of the "to" keyword. Retained for highlighting purposes.Agda3An imported name can be a module or a defined name.AgdaImported module name of type m.AgdaImported name of type n.AgdaThe using clause of import directive.AgdaNo using clause given.Agdausing the specified names.AgdaThe things you are allowed to say when you shuffle names between name spaces (i.e. in import,  namespace, or open declarations).Agda Only for open3. Exports the opened names from the current module.AgdaThe notation is handled as the fixity in the renamer. Hence, they are grouped together in this type.AgdaRange of the name in the fixity declaration (used for correct highlighting, see issue #2140).AgdaFixity of operators.Agda&Range of the whole fixity declaration.AgdaAssociativity.AgdaNo fixity declared.Agda$Fixity level declared as the number.Agda Precedence levels for operators.AgdaPlaceholders are used to represent the underscores in a section.AgdaThe second argument is used only (but not always) for name parts other than underscores.Agda4The position of a name part or underscore in a name.Agda;The following underscore is at the beginning of the name: _foo.Agda8The following underscore is in the middle of the name: foo_bar.Agda4The following underscore is at the end of the name: foo_.AgdaA "problem" consists of a set of constraints and the same constraint can be part of multiple problems.Agda4A meta variable identifier is just a natural number.AgdaThe unique identifier of a name. Second argument is the top-level module identifier.AgdaIs this a macro definition?Agda0Is this definition eligible for instance search?Agda Range of the instance keyword.Agda"Is any element of a collection an .AgdaAbstract or concrete.AgdaAccess modifier.Agda Store the  of the private block that lead to this qualifier. This is needed for more faithful printing of declarations.AgdaFunctions can be defined in both infix and prefix style. See k.Agda"Where does a projection come from?AgdaUser wrote a prefix projection.Agda User wrote a postfix projection.Agda'Projection was generated by the system.AgdaWhere does the ConP or Con come from?Agda8Inserted by system or expanded from an implicit pattern.Agda#User wrote a constructor (pattern).AgdaUser wrote a record (pattern).Agda(Generated by interactive case splitting.AgdaString with range info.AgdaA RawName is some sort of string.AgdaThing with range info.AgdaNames in binders and arguments.AgdaOnly  arguments can have names.AgdaAccessor/editor for the  component.AgdaThe type of the nameAgdaStandard argument names.AgdaStandard naming.Agda&Something potentially carrying a name.Agda4A function argument can be hidden and/or irrelevant.AgdaSometimes we want a different kind of binder/pi-type, without it supporting any of the Modality interface.AgdaA lens to access the : attribute in data structures. Minimal implementation: getFreeVariables and mapFreeVariables or  LensArgInfo.AgdaA lens to access the : attribute in data structures. Minimal implementation:  getOrigin and  mapOrigin or  LensArgInfo.AgdaDecorating something with  information.AgdaOrigin of arguments.Agda/From the source file / user input. (Preserve!)AgdaE.g. inserted hidden arguments.Agda%Produced by the reflection machinery.Agda&Produced by an interactive case split.AgdaNamed application produced to represent a substitution. E.g. "?0 (x = n)" instead of "?0 n"AgdaA lens to access the : attribute in data structures. Minimal implementation:  getCohesion and  mapCohesion or  LensModality.AgdaCohesion modalities see "Brouwer's fixed-point theorem in real-cohesive homotopy type theory" (arXiv:1509.07584) types are now given an additional topological layer which the modalities interact with.Agda=same points, discrete topology, idempotent comonad, box-like.Agdaidentity modality. | Sharp -- ^ same points, codiscrete topology, idempotent monad, diamond-like.Agdasingle point space, artificially added for Flat left-composition.AgdaIn the future there might be different kinds of them. For now we assume lock weakening.AgdaWe have a tuple of annotations, which might not be fully orthogonal.AgdaFitch-style dependent right adjoints. See Modal Dependent Type Theory and Dependent Right Adjoints, arXiv:1804.05236.AgdaA lens to access the : attribute in data structures. Minimal implementation:  getRelevance and  mapRelevance or  LensModality.Agda:A function argument can be relevant or irrelevant. See Agda.TypeChecking.Irrelevance.Agda4The argument is (possibly) relevant at compile-time.AgdaThe argument may never flow into evaluation position. Therefore, it is irrelevant at run-time. It is treated relevantly during equality checking.Agda3The argument is irrelevant at compile- and runtime.AgdaA special case of : erased or not.AgdaQuantity for linearity.A quantity is a set of natural numbers, indicating possible semantic uses of a variable. A singleton set {n}= requires that the corresponding variable is used exactly n times.Agda Zero uses {0}, erased at runtime.Agda Linear use {1} (could be updated destructively). Mostly TODO (needs postponable constraints between quantities to compute uses).AgdaUnrestricted use B.Agda Origin of .AgdaUser wrote nothing.AgdaUser wrote "@".AgdaUser wrote "@plenty".Agda Origin of .AgdaUser wrote nothing.AgdaUser wrote "@1".AgdaUser wrote "@linear".Agda Origin of .AgdaUser wrote nothing.AgdaUser wrote "@0".AgdaUser wrote "@erased".AgdaWe have a tuple of modalities, which might not be fully orthogonal. For instance, irrelevant stuff is also run-time irrelevant.Agda4Legacy irrelevance. See Pfenning, LiCS 2001; AbelVezzosiWinterhalter, ICFP 2017.AgdaCardinality / runtime erasure. See Conor McBride, I got plenty o' nutting, Wadlerfest 2016. See Bob Atkey, Syntax and Semantics of Quantitative Type Theory, LiCS 2018.AgdaCohesion/what was in Agda-flat. see "Brouwer's fixed-point theorem in real-cohesive homotopy type theory" (arXiv:1509.07584) Currently only the comonad is implemented.AgdaType wrapper to indicate composition or multiplicative monoid/semigroup context.Agda;Type wrapper to indicate additive monoid/semigroup context.AgdaA lens to access the : attribute in data structures. Minimal implementation:  getHiding and  mapHiding or  LensArgInfo.AgdaDecorating something with  information.Agda Inductive < CoinductiveAgda0Can we construct a record by copattern matching?Agda/Can we pattern match on the record constructor?Agda=For a record without eta, which type of matching do we allow?Agda$Can match on the record constructor.Agda5Can copattern match using the projections. (Default.)AgdaPattern and copattern matching is allowed in the presence of eta.In the absence of eta, we have to choose whether we want to allow matching on the constructor or copattern matching with the projections. Having both leads to breakage of subject reduction (issue #4560).Agda%Does a record come with eta-equality?AgdaAgda variants.Only some variants are tracked.AgdaVariants of Cubical Agda.Agda4Used to specify whether something should be delayed.AgdaMonoidal composition of  information in some data.Agda arguments are visible.Agda and  arguments are  notVisible.Agda arguments are hidden.AgdaIgnores .Agdam  m' means that an m can be used where ever an m' is required.Agda(Multiplicative monoid (standard monoid).AgdaCompose with modality flag from the left. This function is e.g. used to update the modality information on pattern variables a- after a match against something of modality q.AgdainverseComposeModality r x returns the least modality y such that forall x, y we have .x `moreUsableModality` (r `composeModality` y) iff 5(r `inverseComposeModality` x) `moreUsableModality` y (Galois connection).AgdaLeft division by a 3. Used e.g. to modify context when going into a m argument.3Note that this function does not change quantities.Agda# forms a pointwise additive monoid.AgdaIdentity under additionAgdaIdentity under compositionAgda"Absorptive element under addition.AgdaThe default Modality Beware that this is neither the additive unit nor the unit under composition, because the default quantity is .AgdaEquality ignoring origin.AgdaEquality ignoring origin.Agda. forms an additive monoid with zero Quantity0.AgdaIdentity element under additionAgdaAbsorptive element! This differs from Relevance and Cohesion whose default is the multiplicative unit.Agda"Identity element under compositionAgdaAbsorptive element is .Agdam moreUsableQuantity m' means that an m can be used where ever an m' is required.Agda+Composition of quantities (multiplication). is dominant.  is neutral.Right-biased for origin.AgdaCompose with quantity flag from the left. This function is e.g. used to update the quantity information on pattern variables a- after a match against something of quantity q.AgdainverseComposeQuantity r x returns the least quantity y such that forall x, y we have (x `moreQuantity` (r `composeQuantity` y) iff /(r `inverseComposeQuantity` x) `moreQuantity` y (Galois connection).AgdaLeft division by a 3. Used e.g. to modify context when going into a q argument.Agda Check for .Agda Check for .Agda Check for .Agda*Did the user supply a quantity annotation?Agda9A thing of quantity 0 is unusable, all others are usable.AgdaThe default value of type  : not erased.Agda can be embedded into .Agda can be projected onto .AgdaEquality ignoring origin.AgdaIs the value "erased"?AgdaComposition of values of type . is dominant.  is neutral.Right-biased for the origin.AgdaInformation ordering. Relevant `moreRelevant` NonStrict `moreRelevant` IrrelevantAgdaEquality ignoring origin.AgdausableRelevance rel == False! iff we cannot use a variable of rel.Agda composition.  is dominant, + is neutral. Composition coincides with .AgdaCompose with relevance flag from the left. This function is e.g. used to update the relevance information on pattern variables a! after a match against something rel.AgdainverseComposeRelevance r x returns the most irrelevant y such that forall x, y we have )x `moreRelevant` (r `composeRelevance` y) iff 0(r `inverseComposeRelevance` x) `moreRelevant` y (Galois connection).AgdaLeft division by a 3. Used e.g. to modify context when going into a rel argument.AgdaCombine inferred . The unit is .Agda4 forms a monoid under addition, and even a semiring.Agda"Identity element under compositionAgda"Absorptive element under addition.Agda;Default Relevance is the identity element under compositionAgdaIrrelevant function arguments may appear non-strictly in the codomain type.AgdaApplied when working on types (unless --experimental-irrelevance).AgdaInformation ordering. Flat `moreCohesion` Continuous `moreCohesion` Sharp `moreCohesion` SquashAgdaEquality ignoring origin.AgdausableCohesion rel == False! iff we cannot use a variable of rel.Agda composition.  is dominant,  is neutral.AgdaCompose with cohesion flag from the left. This function is e.g. used to update the cohesion information on pattern variables a- after a match against something of cohesion rel.AgdainverseComposeCohesion r x returns the least y such that forall x, y we have (x `moreCohesion` (r `composeCohesion` y) iff /(r `inverseComposeCohesion` x) `moreCohesion` y1 (Galois connection). The above law fails for  r = Squash.AgdaLeft division by a 3. Used e.g. to modify context when going into a rel argument.AgdaCombine inferred . The unit is .Agda4 forms a monoid under addition, and even a semiring.AgdaIdentity under compositionAgda"Absorptive element under addition.Agda:Default Cohesion is the identity element under compositionAgdaxs `withArgsFrom` args translates xs into a list of s, using the elements in args to fill in the non- fields.5Precondition: The two lists should have equal length.Agda,Equality of argument names of things modulo   and .Agda,Equality of argument names of things modulo   and .AgdaDoes an argument arg fit the shape dom of the next expected argument?The hiding has to match, and if the argument has a name, it should match the name of the domain.~ should be , so use as @ fromMaybe  IMPOSSIBLE $ fittingNamedArg arg dom @AgdaGet the content of a .AgdaThe functor instance for 8 would be ambiguous, so we give it another name here.Agda ,setNamedArg a b = updateNamedArg (const b) aAgdaThing with no range info.Agda)Prefer user-written over system-inserted.AgdaAn abbreviation: noPlaceholder =  .AgdaDefault is directive is private% (use everything, but do not export).AgdaisDefaultImportDir implies null, but not the other way round.AgdaLike partitionEithers.Agda Just for the 9 instance. Should never combine different overlapping.Agda, is an idempotent partial monoid, with unit .  and  are incompatible.AgdaRight-biased composition, because the left quantity acts as context, and the right one as occurrence.AgdaRight-biased composition, because the left quantity acts as context, and the right one as occurrence.AgdaRight-biased composition, because the left quantity acts as context, and the right one as occurrence.AgdaNote that the order is  D 0,1, more options is smaller.AgdaIn the absense of finite quantities besides 0,  is the unit. Otherwise, 1 is the unit.Agda+Composition of quantities (multiplication). is dominant.  is neutral.Right-biased for origin.Agda is the unit under composition.Agda% forms a semigroup under composition.AgdaMore relevant is smaller.AgdaMore relevant is smaller.Agda is the additive unit.Agda" forms a semigroup under addition.Agda Continous is the multiplicative unit.Agda% forms a semigroup under composition.AgdaFlatter is smaller.Agda2Order is given by implication: flatter is smaller.AgdaPointwise additive unit.AgdaPointwise addition.AgdaPointwise composition unit.AgdaPointwise composition.AgdaDominance ordering.AgdaRanges are not forced.AgdaIgnores range.AgdaIgnores range.AgdaIgnores range.Agda Default is .Agda+Semigroup computes if any of several is an .Agda(Show non-record version of this newtype.AgdaRanges are not forced.AgdaRanges are not forced.Agdanull for import directives holds when everything is imported unchanged (no names are hidden or renamed).J Safe-Inferred!!$%&.145789:;Ւ AgdaWhen printing we keep track of a stack of precedences in order to be able to decide whether it's safe to leave out parens around lambdas. An empty stack is equivalent to . Invariant: `notElem TopCtx`.Agda(Precedence is associated with a context.Agda*Do we prefer parens around arguments like  x C x or not? See .AgdaDecorating something with Fixity'.Agda#Argument context preferring parens.AgdaDo we need to bracket an operator application of the given fixity in a context with the given precedence.AgdaDo we need to bracket an operator application of the given fixity in a context with the given precedence.AgdaDoes a lambda-like thing (lambda, let or pi) need brackets in the given context? A peculiar thing with lambdas is that they don't need brackets in certain right operand contexts. To decide we need to look at the stack of precedences and not just the current precedence. Example: mA >>= ( x C x) >>= mA (for _>>=_ left associative).Agda*Does a function application need brackets?Agda*Does a function application need brackets?Agda&Does a with application need brackets?Agda$Does a function space need brackets?K Safe-Inferred"!$%&.145789:; AgdaThe parser monad.AgdaMemoisation keys.AgdaRuns the parser.AgdaParses a token satisfying the given predicate. The computed value is returned.Agda.Parses a token satisfying the given predicate.AgdaUses the given document as the printed representation of the given parser. The document's precedence is taken to be atomP.AgdaMemoises the given parser./Every memoised parser must be annotated with a unique key. (Parametrised parsers must use distinct keys for distinct inputs.)AgdaMemoises the given parser, but only if printing, not if parsing./Every memoised parser must be annotated with a unique key. (Parametrised parsers must use distinct keys for distinct inputs.)Agda&Tries to print the parser, or returns , depending on the implementation. This function might not terminate.L Safe-Inferred!!$%&.145789:;ښAgdaArbitrary JS code.,,M Safe-Inferred!!$%&.145789:;'Agda"Entry of an explicit substitution.&An explicit substitution is a list of CAction"Maybe expression": Expression or reference to meta variable.AgdaAgsy's internal syntax.AgdaLambda with hiding information.AgdaTrue8 if possibly dependent (var not known to not occur). False if non-dependent.Agda&Absurd lambda with hiding information.AgdaUnique identifier of the head.Agda'This application has been type-checked.AgdaHead.Agda Arguments.Agda"Head of application (elimination).Agda Dot pattern.AgdaConstant definitions.AgdaConstant signatures.AgdaFor debug printing.AgdaReference to the Agda constant.AgdaType of constant.AgdaConstant definition.Agda7Free vars of the module where the constant is defined..AgdaAbstraction with maybe a name.Different from Agda, where there is also info whether function is constant.AgdaThe concrete instance of the blk parameter in 8. I.e., the information passed to the search control.AgdaNat - deffreevars (to make cost of using module parameters correspond to that of hints).Agda1Size of typing context in which meta was created.Agda!Head normal form of type of meta.AgdaTrue if iota steps performed when normalising target type (used to put cost when traversing a definition by construction instantiation).Agda;Unique identifiers for variable occurrences in unification.AgdaSubstituting for a variable.AgdaFreeVars class and instancesAgda Renaming Typeclass and instancesN Safe-Inferred!!$%&.145789:;Agda!Moves A move is composed of a Cost: together with an action computing the refined problem.Agda univar sub v figures out what the name of v" "outside" of the substitution sub ought to be, if anything.Agda6List of the variables instantiated by the substitutionAgdaNew constructors Taking a step towards a solution consists in picking a constructor and filling in the missing parts with placeholders to be discharged later on.Agda5New spine of arguments potentially using placeholdersAgdaNew App?lication node using a new spine of arguments respecting the Hiding annotationAgdaEquality reasoning steps The begin token is accompanied by two steps because it does not make sense to have a derivation any shorter than that.AgdaPick the first unused UId amongst the ones you have seen (GA: ??) Defaults to the head of the seen ones.O Safe-Inferred!!$%&.145789:;Agda)Typechecker drives the solution of metas.--P Safe-Inferred"!$%&'.145789:;Agda/Type of a literate preprocessor: Invariants:  f : Processor f pos s /= []f pos s >>= layerContent == sAgdaA list of contiguous layers.Agda9A sequence of characters in a file playing the same role.Agda Role of a character in the file.Agda7Annotates a tokenized string with position information.AgdaList of valid extensions for literate Agda files, and their corresponding preprocessors.If you add new extensions, remember to update test/Utils.hs so that test cases ending in the new extensions are found.AgdaReturns True& if the role corresponds to Agda code.AgdaReturns True! if the layer contains Agda code.AgdaBlanks the non-code parts of a given file, preserving positions of characters corresponding to code. This way, there is a direct correspondence between source positions and positions in the processed result.Agda6Replaces non-space characters in a string with spaces.Agda*Check if a character is a blank character.AgdaShort list of extensions for literate Agda files. For display purposes.AgdaReturns a tuple consisting of the first line of the input, and the rest of the input.Agda2Canonical decomposition of an empty literate file.AgdaCreate a regular expression that: - Must match the whole string - Works across line boundariesAgdaPreprocessor for literate TeX.AgdaPreprocessor for Markdown.Agda"Preprocessor for reStructuredText.Agda$Preprocessor for Org mode documents.Q Safe-Inferred!!$%&.145789:;1AgdaPicking the appropriate set of special characters depending on whether we are allowed to use unicode or have to limit ourselves to ascii.AgdaWe want to know whether we are allowed to insert unicode characters or not.Agda3Are we allowed to use unicode supscript characters?AgdaReturn the glyph set based on a given (unicode or ascii) glyph modeAgda/Choose the glyph set based on the unsafe IORef.R Safe-Inferred!!$%&.145789:;/(Agda+Check whether a name is the empty name "_".Agda3Method by which to generate fresh unshadowed names.Agda1Append an integer Unicode subscript: x, xA, xA, @Agda-Append an integer ASCII counter: x, x1, x2, @AgdaNumber of holes in a $ (i.e., arity of a mixfix-operator).AgdaTop-level module names. Used in connection with the file system.&Invariant: The list must not be empty.AgdaQName is a list of namespaces and the name of the constant. For the moment assumes namespaces are just Names and not explicitly applied modules. Also assumes namespaces are generative by just using derived equality. We will have to define an equality instance to non-generative namespaces (as well as having some sort of lookup table for namespace names).AgdaA.rest.Agdax.Agda overlapping the given range, as well as the rest of the map."AgdaRestricts the " to the given range.#AgdaMerges "s by inserting every "piece" of the smaller one into the larger one.#AgdaMerges "s by inserting every "piece" of the smaller one into the larger one.""""""""""""""""""""""""""""""""""d Safe-Inferred!!$%&.145789:;jP####################################e Safe-Inferred!!$%&.145789:;l#AgdaSeparate by blank line.#Agda1Separate by space that will be removed by minify.For non-removable space, use d <> " " <> d'.#Agda1Concatenate vertically, separated by blank lines.#AgdaApply # to # if boolean is true.#AgdaCheck if a string is a valid JS identifier. The check ignores keywords as we prepend z_ to our identifiers. The check is conservative and may not admit all valid JS identifiers.(########################################(#########################################5#5#6f Safe-Inferred!!$%&.145789:;n#AgdaSpeculation: Type class computing the size (?) of a pattern and collecting the vars it introduces$AgdaTake a list of patterns and returns (is, size, vars) where (speculation):4################################################$$$$4##############################################$##$$$g Safe-Inferred!!$%&.145789:;%$Agda SCC DAGs.0The maps map SCC indices to and from SCCs/nodes.$AgdaWithUniqueInt n consists of pairs of (unique) ~s and values of type n.2Values of this type are compared by comparing the ~s.$AgdaVarious kinds of nodes.$AgdaNodes with outgoing edges.$AgdaNodes with incoming edges.$Agda!All nodes, with or without edges.$AgdaEdges.$AgdaOutgoing node.$AgdaIncoming node.$AgdaEdge label (weight).$Agda Graph n e, is a type of directed graphs with nodes in n and edges in e.At most one edge is allowed between any two nodes. Multigraphs can be simulated by letting the edge type e be a collection type.The graphs are represented as adjacency maps (adjacency lists, but using finite maps instead of arrays and lists). This makes it possible to compute a node's outgoing edges in logarithmic time (O(log n)). However, computing the incoming edges may be more expensive.Note that neither the number of nodes nor the number of edges may exceed  :: ~.$AgdaForward edges.$AgdaInternal invariant.$AgdaIf there is an edge from s to t, then  lookup s t g is ~ e, where e is the edge's label. O(log n).$AgdaThe graph's edges. O(n + e).$Agdaneighbours u g consists of all nodes v" for which there is an edge from u to v in g-, along with the corresponding edge labels.  O(log n + |neighbours u g|).$AgdaneighboursMap u g consists of all nodes v" for which there is an edge from u to v in g-, along with the corresponding edge labels. O(log n).$AgdaedgesFrom g ns is a list containing all edges originating in the given nodes (i.e., all outgoing edges for the given nodes). If ns does not contain duplicates, then the resulting list does not contain duplicates. O(|ns| log |n| + |edgesFrom g ns|).$Agda edgesTo g ns is a list containing all edges ending in the given nodes (i.e., all incoming edges for the given nodes). If ns does not contain duplicates, then the resulting list does not contain duplicates. O(|ns | n log n).$AgdaAll self-loops.  O(n log n).$Agda All nodes. O(n).$AgdaNodes with outgoing edges. O(n).$AgdaNodes with incoming edges. O(n + e log n).$Agda Constructs a $ structure. O(n + e log n).$Agda*Nodes without incoming or outgoing edges. O(n + e log n).$AgdaChecks whether the graph is discrete (containing no edges other than  edges). O(n + e).$AgdaReturns True iff the graph is acyclic.$AgdaConstructs a completely disconnected graph containing the given nodes.  O(n log n).$AgdaConstructs a completely disconnected graph containing the given nodes. O(n).$Agda fromEdges es$ is a graph containing the edges in es=, with the caveat that later edges overwrite earlier edges. O(|es| log n).$AgdafromEdgesWith f es$ is a graph containing the edges in es. Later edges are combined with earlier edges using the supplied function. O(|es| log n).$Agda"Empty graph (no nodes, no edges). O(1).$Agda5A graph with two nodes and a single connecting edge. O(1).$Agda Inserts an edge into the graph. O(log n).$Agda Inserts an edge into the graph. O(log n).$AgdainsertWith f s t new inserts an edge from s to t3 into the graph. If there is already an edge from s to t with label old6, then this edge gets replaced by an edge with label  f new old%, and otherwise the edge's label is new. O(log n).$Agda A variant of $. O(log n).$AgdaLeft-biased union.Time complexity: See $.$AgdaUnion. The function is used to combine edge labels for edges that occur in both graphs (labels from the first graph are given as the first argument to the function).Time complexity:  O(nA log (nAnA + 1) + eA log eA), where nA/ is the number of nodes in the graph with the smallest number of nodes and nA0 is the number of nodes in the other graph, and eA is the number of edges in the graph with the smallest number of edges and eA+ is the number of edges in the other graph."Less complicated time complexity: O((n + e) log n (where n and e refer to the resulting graph).$AgdaUnion. O((n + e) log n (where n and e refer to the resulting graph).$AgdaUnion. The function is used to combine edge labels for edges that occur in several graphs. O((n + e) log n (where n and e refer to the resulting graph).$Agda A variant of < that provides extra information to the function argument. O(n + e).$AgdaReverses an edge. O(1).$Agda.The opposite graph (with all edges reversed). O((n + e) log n).$AgdaRemoves  edges. O(n + e).$Agda The graph filterNodes p g# contains exactly those nodes from g that satisfy the predicate p=. Edges to or from nodes that are removed are also removed. O(n + e).$AgdaremoveNodes ns g removes the nodes in ns% (and all corresponding edges) from g. O((n + e) log |ns|).$AgdaremoveNode n g removes the node n% (and all corresponding edges) from g. O(n + e).$AgdaremoveEdge s t g removes the edge going from s to t , if any. O(log n).$Agda0Keep only the edges that satisfy the predicate. O(n + e).$AgdaRemoves the nodes that do not satisfy the predicate from the graph, but keeps the edges: if there is a path in the original graph between two nodes that are retained, then there is a path between these two nodes also in the resulting graph.(Precondition: The graph must be acyclic.Worst-case time complexity:  O(e n log n)) (this has not been verified carefully).$AgdaRenames the nodes.6Precondition: The renaming function must be injective.Time complexity: O((n + e) log n).$AgdaRenames the nodes.$Precondition: The renaming function ren" must be strictly increasing (if x  y then ren x  ren y).Time complexity: O(n + e).$Agda'Combines each node label with a unique ~.Precondition: The number of nodes in the graph must not be larger than  :: ~.Time complexity: O(n + e log n).$AgdaUnzips the graph. O(n + e).$AgdacomposeWith times plus g g' finds all edges s --c_i--> t_i --d_i--> u) and constructs the result graph from !edge(s,u) = sum_i (c_i times d_i).Complexity: For each edge s --> t in g' we look up all edges starting with t in g'.>Precondition: The two graphs must have exactly the same nodes.$AgdaThe graph's strongly connected components, in reverse topological order.The time complexity is likely O(n + e log n) (but this depends on the, at the time of writing undocumented, time complexity of ).$AgdaThe graph's strongly connected components, in reverse topological order.The time complexity is likely O(n + e log n) (but this depends on the, at the time of writing undocumented, time complexity of ).$Agda$ invariant.$AgdaThe opposite DAG.$Agda'The nodes reachable from the given SCC.$AgdaConstructs a DAG containing the graph's strongly connected components.$AgdaConstructs a DAG containing the graph's strongly connected components.$AgdareachableFrom g n/ is a map containing all nodes reachable from n in g. For each node a simple path to the node is given, along with its length (the number of edges). The paths are as short as possible (in terms of the number of edges).Precondition: n must be a node in g<. The number of nodes in the graph must not be larger than  :: ~.Amortised time complexity (assuming that comparisons take constant time):  O(e log n), if the lists are not inspected. Inspection of a prefix of a list is linear in the length of the prefix.$AgdareachableFromSet g ns/ is a set containing all nodes reachable from ns in g.Precondition: Every node in ns must be a node in g<. The number of nodes in the graph must not be larger than  :: ~.Amortised time complexity (assuming that comparisons take constant time): O((|ns | + e) log n).AgdaUsed to implement $ and $.$Agda#walkSatisfying every some g from to% determines if there is a walk from from to to in g/, in which every edge satisfies the predicate every(, and some edge satisfies the predicate some. If there are several such walks, then a shortest one (in terms of the number of edges) is returned.Precondition: from and to must be nodes in g<. The number of nodes in the graph must not be larger than  :: ~.Amortised time complexity (assuming that comparisons and the predicates take constant time to compute): O(n + e log n).$AgdaConstructs a graph g', with the same nodes as the original graph g. In g' there is an edge from n1 to n2> if and only if there is a (possibly empty) simple path from n1 to n2 in g. In that case the edge is labelled with all of the longest (in terms of numbers of edges) simple paths from n1 to n2 in g), as well as the lengths of these paths.Precondition: The graph must be acyclic. The number of nodes in the graph must not be larger than  :: ~.>Worst-case time complexity (if the paths are not inspected):  O(e n log n)( (this has not been verified carefully).1The algorithm is based on one found on Wikipedia.$AgdaTransitive closure ported from Agda.Termination.CallGraph.%Relatively efficient, see Issue 1560.$Agda Version of $ that produces a list of intermediate results paired to the left with a difference that lead to the new intermediat result.The last element in the list is the transitive closure, paired with the empty graph. (complete g = snd $ last $ completeIter g$Agda-Computes the transitive closure of the graph.Uses the Gauss-Jordan-Floyd-Warshall-McNaughton-Yamada algorithm (as described by Russell O'Connor in "A Very General Method of Computing Shortest Paths"  'http://r6.ca/blog/20110808T035622Z.html), implemented using matrices.4The resulting graph does not contain any zero edges.This algorithm should be seen as a reference implementation. In practice $! is likely to be more efficient.$Agda-Computes the transitive closure of the graph.Uses the Gauss-Jordan-Floyd-Warshall-McNaughton-Yamada algorithm (as described by Russell O'Connor in "A Very General Method of Computing Shortest Paths"  'http://r6.ca/blog/20110808T035622Z.html), implemented using $, and with some shortcuts:Zero edge differences are not added to the graph, thus avoiding some zero edges.Strongly connected components are used to avoid computing some zero edges.The graph's strongly connected components (in reverse topological order) are returned along with the transitive closure.$AgdaThe transitive closure. Using $. NOTE: DO NOT USE () AS EDGE LABEL SINCE THIS MEANS EVERY EDGE IS CONSIDERED A ZERO EDGE AND NO NEW EDGES WILL BE ADDED! Use 'Maybe ()' instead.$AgdaThe transitive reduction of the graph: a graph with the same reachability relation as the graph, but with as few edges as possible.Precondition: The graph must be acyclic. The number of nodes in the graph must not be larger than  :: ~.Worst-case time complexity:  O(e n log n)) (this has not been verified carefully).1The algorithm is based on one found on Wikipedia.$Agda*The graph's strongly connected components.$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$h Safe-Inferred!!$%&.145789:;P$Agdatopoligical sort with smallest-numbered available vertex first | input: nodes, edges | output is Nothing if the graph is not a DAG Note: should be stable to preserve order of generalizable variables. Algorithm due to Richard Eisenberg, and works by walking over the list left-to-right and moving each node the minimum distance left to guarantee topological ordering.$$i Safe-Inferred!!$%&.145789:;q%$AgdaThese metas are < D.$Agda,Lower or upper bound for a flexible variable%AgdaA graph forest.%Agda Going from Lt to Le is pred , going from Le to Lt is succ.X --(R,n)--> Y means  X (R) Y + n#. [ ... if n positive and X + (-n) (R) Y if n negative. ]%AgdaNodes not connected.%Agda4Test for negativity, used to detect negative cycles.%Agda1Compute list of edges that start in a given node.%Agda/Compute list of edges that target a given node.9Note: expensive for unidirectional graph representations.%Agda Set.foldl* does not exist in legacy versions of the  containers package.%AgdaFloyd-Warshall algorithm.%Agda5Convert a label to a weight, decrementing in case of  .%AgdaSplit a list of graphs gs into those that mention node n and those that do not. If n6 is zero or infinity, we regard it as "not mentioned".%AgdaAdd an edge to a graph forest. Graphs that share a node with the edge are joined.%AgdaReflexive closure. Add edges 0 -> n -> n -> oo for all nodes n.%Agdah % g if any edge in g between rigids and constants is implied by a corresponding edge in h", which means that the edge in g/ carries at most the information of the one in h.Application: Constraint implication: Constraints are compatible with hypotheses.%Agda2Build a graph from list of simplified constraints.%Agda2Build a graph from list of simplified constraints.%AgdaIf we have an edge  X + n <= X (with n >= 0), we must set X = oo.%Agda2Compute a lower bound for a flexible from an edge.%Agda3Compute an upper bound for a flexible from an edge.%Agda6Compute the lower bounds for all flexibles in a graph.%Agda6Compute the upper bounds for all flexibles in a graph.%Agda0Compute the bounds for all flexibles in a graph.%AgdaCompute the relative minima in a set of nodes (those that do not have a predecessor in the set).%AgdaCompute the relative maxima in a set of nodes (those that do not have a successor in the set).%AgdaGiven source nodes n1,n2,... find all target nodes m1,m2, such that for all j, there are edges n_i --l_ij--> m_j for all i. Return these edges as a map from target notes to a list of edges. We assume the graph is reflexive-transitive.%AgdaGiven target nodes m1,m2,... find all source nodes n1,n2, such that for all j, there are edges n_i --l_ij--> m_j for all i. Return these edges as a map from target notes to a list of edges. We assume the graph is reflexive-transitive.%AgdaCompute the sup of two different rigids or a rigid and a constant.%AgdaCompute the inf of two different rigids or a rigid and a constant.%Agda$Compute the least upper bound (sup).%AgdaCompute the greatest lower bound (inf) of size expressions relative to a hypotheses graph.%AgdaSolve a forest of constraint graphs relative to a hypotheses graph. Concatenate individual solutions.%AgdaCheck that after substitution of the solution, constraints are implied by hypotheses.%Agda1Iterate solver until no more metas can be solved.This might trigger a (wanted) error on the second iteration (see Issue 2096) which would otherwise go unnoticed.%AgdaPartial implementation of Num.%Agda$An edge is negative if its label is.%Agda A graph is % if it contains a negative loop (diagonal edge). Makes sense on transitive graphs.%Agda;Meta variable polarities (prefer lower or upper solution?).AgdaHypotheses (assumed to have no metas, so, fixed during iteration).AgdaConstraints to solve.Agda7Previous substitution (already applied to constraints).AgdaAccumulated substition.$$$$$$%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%$%$$$$$%%%%%%%%%%%%%%%%%%%%j Safe-Inferred!!$%&.145789:;%AgdaSubterm occurrences for positivity checking. The constructors are listed in increasing information they provide: 3Mixed <= JustPos <= StrictPos <= GuardPos <= Unused Mixed <= JustNeg <= Unused.%Agda-Arbitrary occurrence (positive and negative).%AgdaNegative occurrence.%Agda/Positive occurrence, but not strictly positive.%AgdaStrictly positive occurrence.%AgdaGuarded strictly positive occurrence (i.e., under D). For checking recursive records.%Agda-One part of the description of an occurrence.%Agda(in the nth argument of a define constant%Agda'in the principal argument of built-in D%Agda"as an argument to a bound variable&Agda as an argument of a metavariable&Agdain the type of a constructor&Agda$in a datatype index of a constructor&Agda'in the nth clause of a defined function&Agda1matched against in a clause of a defined function&Agda"is an index of an inductive family&Agdain the definition of a constant&AgdaDescription of an occurrence.&AgdaThe elements of the sequences, read from left to right, explain how to get to the occurrence. The second sequence includes the main information, and if the first sequence is non-empty, then it includes information about the context of the second sequence.&Agda&The map contains bindings of the form  bound |-> ess?, satisfying the following property: for every non-empty list w,   w  bound iff  [  every w   some w | (every, some) <- ess ].&Agda+productOfEdgesInBoundedWalk occ g u v bound returns a value distinct from ~ iff there is a walk c (a list of edges) in g, from u to v, for which the product   ( occ c)  bound&. In this case the returned value is ~ (  c) for one such walk c.Preconditions: u and v must belong to g, and bound must belong to the domain of boundToEverySome.&Agda%* is a complete lattice with least element % and greatest element %.&It forms a commutative semiring where  is meet (glb) and 0 is composition. Both operations are idempotent.For , % is neutral (zero) and % is dominant. For , % is neutral (one) and % is dominant.%%%%%%%%%%%%&&&&&&&&&&&%%%%%%%&&%%%%%&&&&&&&&&k Safe-Inferred#!$%&.1245789:;;&AgdaThe ' is not an application.&Agda(Extended content of an interaction hole.&Agda e&Agda  (rewrite | invert) e0 | ... | en&Agda=Modules: Top-level pragmas plus other top-level declarations.&Agda$Second Range is for REWRITE keyword.&Agdafirst string is backend name&Agdafirst string is backend name&AgdaINLINE or NOINLINE&Agda6Throws an internal error in the scope checker. The +s are words to be displayed with the error.&Agda:For coinductive records, use pragma instead of regular  eta-equality, definition (as it is might make Agda loop).&AgdaApplies to the named function&AgdaApplies to the current module&AgdaMark a definition as injective for the pattern matching unifier.&Agda*Display lhs as rhs (modifies the printer).&Agda)Applies to the following function clause.&AgdaApplies to the following function (and all that are mutually recursive with it) or to the functions in the following mutual block.&AgdaApplies to the following function (and all that are mutually recursive with it) or to the functions in the following mutual block.&Agda:Applies to the following data/record type or mutual block.&Agda*Applies to the following data/record type.&Agda  tel. M args&Agda  M {{...}}&AgdaThe representation type of a declaration. The comments indicate which type in the intended family the constructor targets.&AgdaAxioms and functions can be irrelevant. (Hiding should be NotHidden)&Agda=Variables to be generalized, can be hidden and/or irrelevant.&Agda#lone data signature in mutual block&Agda%lone record signature in mutual block&Agda$Should not survive beyond the parser&Agdanotation declaration for a name&AgdaIn  Agda.Syntax.Concrete.Definitions we generate private blocks temporarily, which should be treated different that user-declared private blocks. Thus the .&AgdaThe  9 here (exceptionally) only refers to the range of the instance( keyword. The range of the whole block InstanceB r ds is fuseRange r ds.&Agda1Isolated record directives parsed as Declarations&AgdaRange of keyword  [co]inductive.&Agda Range of [no-]eta-equality keyword.&AgdaIf declaration pattern is present, give its range.&Agda(Just type signatures or instance blocks.AgdaJust field signatures&AgdaJust type signatures.&Agda.From the parser, we get an expression for the as-#, which we have to parse into a .&AgdaThe content of the as -clause of the import statement.&AgdaThe "as" name.&AgdaThe range of the "as" keyword. Retained for highlighting purposes.&Agda3An imported name can be a module or a defined name.&AgdaThe things you are allowed to say when you shuffle names between name spaces (i.e. in import,  namespace, or open declarations).&AgdaAn expression followed by a where clause. Currently only used to give better a better error message in interaction.'AgdaPossibly empty sequence.'AgdaNo where clauses.'Agda Ordinary where.   of the where/ keyword. List of declarations can be empty.'Agda Named where: module M where ds.   of the keywords module and where . The  flag applies to the  (not the module contents!) and is propagated from the parent function. List of declarations can be empty.'Agdawhere block following a clause.'Agda+No right hand side because of absurd match.'Agda:Processed (operator-parsed) intermediate form of the core f ps of '. Corresponds to '.'Agda f'Agda ps'AgdaRecord projection.'Agda-Patterns for record indices (currently none).'AgdaMain argument.'AgdaNon-empty; at least one (| p).'Agda+Pattern that was expanded from an ellipsis ....'Agda;Left hand sides can be written in infix style. For example: +n + suc m = suc (n + m) (f D g) x = f (g x)We use fixity information to see which name is actually defined.'AgdaOriginal pattern (including with-patterns), rewrite equations and with-expressions.'Agdae.g.  f ps | wps'Agda(rewrite e | with p <- e in eq) (many)'Agdawith e1 in eq | {e2} | ... (many)'AgdaA telescope is a sequence of typed bindings. Bound variables are in scope in later types.'AgdaBinding (x1@p1 ... xn@pn : A).'Agda Let binding (let Ds) or  (open M args).'AgdaA typed binding.'Agda. x or {x} or .x or .{x} or {.x} or x@p or (p)'Agda. (xs : e) or {xs : e}'Agda0A lambda binding is either domain free or typed.'Agda A Binder x@p, the pattern is optional'Agda p C e where cs'Agda9Concrete patterns. No literals in patterns at the moment.'Agdac or x'Agda quote'Agdap p' or  p {x = p'}'Agdap1..pn before parsing operators'Agdaeg: p => p' for operator _=>_ The  is possibly ambiguous, but it must correspond to one of the names in the set.'Agda{p} or {x = p}'Agda{{p}} or  {{x = p}}'Agda (p)'Agda _'Agda ()'Agdax@p unused'Agda .e'Agda0, 1, etc.'Agda record {x = p; y = q}'Agdai = i1$ i.e. cubical face lattice generator'Agda...., only as left-most pattern. Second arg is Nothing before expansion, and Just p after expanding ellipsis to p.'Agda| p, for with-patterns.'AgdaConcrete expressions. Should represent exactly what the user wrote.'Agdaex: x'Agdaex: 1 or "foo"'Agdaex: ? or  {! ... !}'Agdaex: _ or _A_5'Agdabefore parsing operators'Agdaex: e e, e {e}, or  e {x = e}'Agdaex: e + e The  is possibly ambiguous, but it must correspond to one of the names in the set.'Agdaex: e | e1 | .. | en'Agdaex: {e} or {x=e}'Agdaex: {{e}} or {{x=e}}'Agdaex:  \x {y} -> e or \(x:A){y:B} -> e'Agdaex: \ ()'Agdaex: .\ { p11 .. p1a -> e1 ; .. ; pn1 .. pnz -> en }'Agdaex: e -> e or .e -> e (NYI: {e} -> e)'Agdaex:  (xs:e) -> e or  {xs:e} -> e'Agdaex: record {x = a; y = b}, or record { x = a; M1; M2 }'Agdaex: record e {x = a; y = b}'Agdaex:  let Ds in e+, missing body when parsing do-notation let'Agdaex: (e)'Agdaex: (| e1 | e2 | .. | en |) or (|)'Agdaex: do x <- m1; m2'Agdaex: () or {}, only in patterns'Agdaex: x@p, only in patterns'Agdaex: .p, only in patterns'Agdaex: ..A, used for parsing ..A -> B'Agda!only used for printing telescopes'Agdaex: quote, should be applied to a name'Agdaex:  quoteTerm, should be applied to a term'Agdaex:  @(tactic t)", used to declare tactic arguments'Agdaex: unquote&, should be applied to a term of type Term'Agdato print irrelevant things'Agdaex: a = b, used internally in the parser'Agda...$, used internally to parse patterns.'AgdaAn abstraction inside a special syntax declaration (see Issue 358 why we introduce this).(Agda-Drop type annotations and lets from bindings.(AgdaWe can try to get a  Telescope from a  [LamBinding]. If we have a type annotation already, we're happy. Otherwise we manufacture a binder with an underscore for the type.(AgdaSmart constructor for Pi: check whether the  Telescope is empty(AgdaSmart constructor for Lam: check for non-zero bindings.(AgdaSmart constructor for Let": check for non-zero let bindings.(AgdaSmart constructor for TLet": check for non-zero let bindings.(AgdaExtract a record directive(Agda#Computes the top-level module name.Precondition: The & has to be well-formed. This means that there are only allowed declarations before the first module declaration, typically import declarations. See (.(AgdaSplits off allowed (= import) declarations before the first non-allowed declaration. After successful parsing, the first non-allowed declaration should be a module declaration.(Agda*Observe the hiding status of an expression(Agda-Observe the relevance status of an expression(Agda2Observe various modifiers applied to an expression(AgdaTurn an expression into a pattern. Fails if the expression is not a valid pattern.(AgdaTurn an expression into a pattern, turning non-pattern subexpressions into '.Agda)Generic expression to pattern conversion.(AgdaA ' is  when the where keyword is absent. An empty list of declarations does not count as  here.(AgdaRanges are not forced.(AgdaRanges are not forced.(AgdaRanges are not forced.(AgdaRanges are not forced.(AgdaRanges are not forced.(AgdaRanges are not forced.(AgdaRanges are not forced.(AgdaRanges are not forced.(AgdaRanges are not forced.Agda&Default result for non-pattern things.AgdaThe expression to translate.AgdaThe translated pattern (maybe).&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''((((((((((((((((((((((((((((((('''''''''''''''''''''''''''''''''''''((''&&((((((((((('''''((''''('''''''''''((''''''''''(('''(((((&&&&&(&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&'''''''''''''''''''''''''''''''''''''''(((&'''''''''''''&&''''&&&&&&&&&&&&&&&&&&&&&&&&&&&&((l Safe-Inferred!!$%&.145789:;)AgdaprettyHiding info visible doc# puts the correct braces around doc according to info info and returns  visible doc% if the we deal with a visible thing.*))))))))))))))))))))))))))))))))))))))))m Safe-Inferred!!$%&.145789:; *Agda~ for root of split tree*AgdaTag for labeling branches of a split tree. Each branch is associated to either a constructor or a literal, or is a catchall branch (currently only used for splitting on a literal type).*AgdaSplit tree branching. A finite map from constructor names to splittrees A list representation seems appropriate, since we are expecting not so many constructors per data type, and there is no need for random access.*AgdaAbstract case tree shape.*AgdaNo more splits coming. We are at a single, all-variable clause.*AgdaA split is necessary.*Agda+The number of variables bound in the clause*AgdaArg. no to split at.*AgdaSub split trees.*AgdaConvert a split tree into a  (for printing).)*****************************************)*******n Safe-Inferred!!$%&.145789:;" *Agda-Sections, as well as non-sectioned operators.*Agda>For non-sectioned operators this should match the notation's *.*AgdaEffective precedence level. ~ for closed notations.*Agda for non-sectioned operators.*Agda/All the notation information related to a name.*Agda-The names the syntax and/or fixity belong to.Invariant: The set is non-empty. Every name in the list matches *.*Agda3Associativity and precedence (fixity) of the names.*Agda!Syntax associated with the names.*AgdaTrue if the notation comes from an operator (rather than a syntax declaration).*AgdaClassification of notations.*AgdaEx:  _bla_blub_.*AgdaEx:  _bla_blub.*AgdaEx:  bla_blub_.*AgdaEx: bla_blub.*Agda8Data type constructed in the Happy parser; converted to $ before it leaves the Happy code.*Agda x -> y2; 1st argument is the bound name (unused for now).*AgdaSimple named hole with hiding.*AgdaIs the hole a binder?*Agda2Get a flat list of identifier parts of a notation.*AgdaTarget argument position of a part (Nothing if it is not a hole).*AgdaIs the part a hole? WildHoles don't count since they don't correspond to anything the user writes.*AgdaIs the part a normal hole?*AgdaIs the part a binder?*AgdaBenchmark a pure computation and bill it to the given account./***+++++++************++***+********+****++++++/*+++++++************++***+********+******++++++p Safe-Inferred!!$%&.145789:;?+AgdaGeneric pattern traversal.See .+Agda Fold pattern.+AgdaCombine a pattern and the value computed from its subpatterns.+Agda;Combine a pattern and the its recursively computed version.+Agdapre : Modification before recursion.Agdapost: Modification after recursion.+Agdapre : Modification before recursion.+Agdapost: Modification after recursion.!+++++++++++++++++++++++++++++++++!+++++++++++++++++++++++++++++++++q Safe-Inferred$!$%&().0145789:;p +AgdaA singleton type for * (except for the constructor *).+Agda"Used to define the return type of +.+AgdaShould sections be parsed?+AgdaThe  is possibly ambiguous, but it must correspond to one of the names in the set.+AgdaRuns a parser. If sections should be parsed, then identifiers with at least two name parts are split up into multiple tokens, using  to record the tokens' original positions within their respective identifiers.+Agda)Parse a specific identifier as a NamePart+AgdaParses a split-up, unqualified name consisting of at least two name parts.The parser does not check that underscores and other name parts alternate. The range of the resulting name is the range of the first name part that is not an underscore.+Agda,Parses a potentially pattern-matching binder+Agda0Parse the "operator part" of the given notation.Normal holes (but not binders) at the beginning and end are ignored.If the notation does not contain any binders, then a section notation is allowed."++++++++++++++++++++++++++++++++++"++++++++++++++++++++++++++++++++++r Safe-Inferred!!$%&.145789:;&+Agda,Generic traversals for concrete expressions. Note: does not go into patterns!+AgdaThis corresponds to .+AgdaThis corresponds to .+AgdaThis corresponds to .++++++++s Safe-Inferred"!$%&.145789:;AgdaWhile , and Polarities are not semigroups under disjoint union (which might fail), we get a semigroup instance for the monadic m (Fixities, Polarities)% which propagates the first error.AgdaAdd more fixities. Throw an exception for multiple fixity declarations. OR: Disjoint union of fixity maps. Throws exception if not disjoint.,AgdaGet the fixities and polarity pragmas from the current block. Doesn't go inside modules and where blocks. The reason for this is that these declarations have to appear at the same level (or possibly outside an abstract or mutual block) as their target declaration.AgdaCompute the names defined in a declaration. We stay in the current scope, i.e., do not go into modules. ,,,,,,,,,,,,, ,,,,,,,,,,,,,t Safe-Inferred!!$%&.145789:;)z,Agda$The kind of the forward declaration.,AgdaName of a data type,AgdaName of a record type,AgdaName of a function.,Agdawe are nicifying a mutual block,Agda,we are nicifying decls not in a mutual block,AgdaSeveral declarations expect only type signatures as sub-declarations. These are:,Agda  postulate,Agda primitive. Ensured by parser.,Agdainstance. Actually, here all kinds of sub-declarations are allowed a priori.,Agdafield. Ensured by parser.,Agdadata ... where=. Here we got a bad error message for Agda-2.5 (Issue 1698).,Agda constructor, in interleaved mutual.,AgdaNumbering declarations in an interleaved mutual block.,Agda&Internal number of the data signature.,AgdaThe data signature.,Agda.Constructors associated to the data signature.,Agda6Function clauses associated to the function signature.,AgdaIn an `interleaved mutual' block we collect the data signatures, function signatures, as well as their associated constructors and function clauses respectively. Each signature is given a position in the block (from 0 onwards) and each set of constructor / clauses is given a *distinct* one. This allows for interleaved forward declarations similar to what one gets in a new-style mutual block.,AgdaIn an inferred mutual block we keep accumulating nice declarations until all of the lone signatures have an attached definition. The type is therefore a bit span-like: we return an initial segment (the inferred mutual block) together with leftovers.,AgdaWhen processing a mutual block we collect the various checks present in the block before combining them.,AgdaOne clause in a function definition. There is no guarantee that the ' actually declares the #. We will have to check that later.,AgdaOnly ,s.,AgdaOnly ,s.,Agda1Termination measure is, for now, a variable name.,AgdaThe nice declarations. No fixity declarations and function definitions are contained in a single constructor instead of spread out between type signatures and clauses. The private,  postulate, abstract and instance modifiers have been distributed to the individual declarations. Observe the order of components:Range Fixity' Access IsAbstract IsInstance TerminationCheck PositivityCheckfurther attributes(Q)Namecontent (Expr, Declaration ...),Agda: argument: We record whether a declaration was made in an abstract block. argument: Axioms and functions can be declared irrelevant. ( should be .),AgdaAn uncategorized function clause, could be a function clause without type signature or a pattern lhs (e.g. for irrefutable let). The & is the actual &.,AgdaBlock of function clauses (we have seen the type signature before). The &s are the original declarations that were processed into this , and are only used in notSoNiceDeclaration9. Andreas, 2017-01-01: Because of issue #2372, we add 6 here. An alias should know that it is an instance.,Agda (Maybe Range) gives range of the  'pattern' declaration.,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,u Safe-Inferred!!$%&.145789:;4J"-Agda-Non-fatal errors encountered in the Nicifier.-AgdaEmpty abstract block.-AgdaEmpty  constructor block.-AgdaEmpty field block.-AgdaEmpty variable block.-AgdaEmpty instance block-AgdaEmpty macro block.-AgdaEmpty mutual block.-AgdaEmpty  postulate block.-AgdaEmpty private block.-AgdaEmpty  primitive block.-AgdaA {-# CATCHALL #-} pragma that does not precede a function clause.-Agda)Invalid definition in a constructor block-AgdaInvalid constructor block (not inside an interleaved mutual block)-AgdaA {-# NON_COVERING #-} pragma that does not apply to any function.-AgdaA {-# NO_POSITIVITY_CHECK #-} pragma that does not apply to any data or record type.-AgdaA {-# NO_UNIVERSE_CHECK #-} pragma that does not apply to a data or record type.-Agda?A record directive outside of a record / below existing fields.-AgdaA {-# TERMINATING #-} and {-# NON_TERMINATING #-} pragma that does not apply to any function.-AgdaDefinitions (e.g. constructors or functions) without a declaration.-Agda9Declarations (e.g. type signatures) without a definition.-Agdaprivate has no effect on  open public!. (But the user might think so.)-Agdaabstract has no effect on  open public!. (But the user might think so.)-AgdaPragma {-# NO_TERMINATION_CHECK #-} has been replaced by {-# TERMINATING #-} and {-# NON_TERMINATING #-}.-AgdaCOMPILE% pragmas are not allowed in safe mode-Agdaabstract6 block with nothing that can (newly) be made abstract.-Agdainstance8 block with nothing that can (newly) become an instance.-Agdaprivate5 block with nothing that can (newly) be made private.-AgdaThe exception type.-AgdaIn a mutual block, a clause could belong to any of the D2 type signatures ().-AgdaIn an interleaved mutual block, a constructor could belong to any of the data signatures ()-AgdaIn a mutual block, all or none need a MEASURE pragma. Range is of mutual block.-Agda-Exception with internal source code callstack-Agda(Nicifier warnings turned into errors in --safe mode.<------------------------------------------------------------<------------------------------------------------------------v Safe-Inferred!!$%&.145789:;>-AgdaIf !, this name can have a different  than the key of - pointing to it.-AgdaNicifier state.-Agda4Lone type signatures that wait for their definition.-Agda5Termination checking pragma waiting for a definition.-Agda4Positivity checking pragma waiting for a definition.-AgdaUniverse checking pragma waiting for a data/rec signature or definition.-Agda.Catchall pragma waiting for a function clause.-Agda)Coverage pragma waiting for a definition.-Agda(Stack of warnings. Head is last warning.-AgdaWe distinguish different &s (anonymous definitions) by a unique .-AgdaNicifier monad. Preserve the state when throwing an exception.-AgdaRun a Nicifier computation, return result and warnings (in chronological order).-AgdaInitial nicifier state.-AgdaLens for field -.-AgdaAdding a lone signature to the state. Return the name (which is made unique if ).-Agda'Remove a lone signature from the state.-Agda"Search for forward type signature.-Agda4Check that no lone signatures are left in the state.-AgdaEnsure that all forward declarations have been given a definition.-Agda?Get names of lone function signatures, plus their unique names.-Agda Create a - map from an association list.-AgdaLens for field -.-AgdaLens for field -.-AgdaLens for field -.-AgdaGet universe check pragma from a data/rec signature. Defaults to .-AgdaLens for field -.-Agda>Get current catchall pragma, and reset it for the next clause.-AgdaAdd a new warning.-Agda(Stack of warnings. Head is last warning.-AgdaWe retain the  also in the codomain since  as a key is up to Eq Name which ignores the range. However, without range names are not unique in case the user gives a second definition of the same name. This causes then problems in  replaceSigs, which might replace the wrong signature.Another reason is that we want to distinguish different occurrences of ) in a mutual block (issue #4157). The $ in the codomain will have a unique .1----------------------------------------------...1----------------------------------------------...w Safe-Inferred!!$%&.145789:;B.Agda(Conjunctive constraint.).AgdaAn attribute is a modifier for ..AgdaModifiers for ..AgdaModifiers for ..AgdaModifiers for ..Agda#Concrete syntax for all attributes..Agda#Parsing a string into an attribute..Agda(Parsing an expression into an attribute..Agda!Setting an attribute (in e.g. an ). Overwrites previous value..AgdaSetting some attributes in left-to-right order. Blindly overwrites previous settings..AgdaSetting  if unset..AgdaSetting  if unset..AgdaSetting  if unset..AgdaSetting  if unset..Agda'Setting an unset attribute (to e.g. an )..Agda#Setting a list of unset attributes.........................................................x Safe-Inferred"!$%&.145789:;J8 .Agda;Result of comparing a candidate with the current favorites..AgdaGreat, you are dominating a possibly (empty list of favorites) but there is also a rest that is not dominated. If null dominated, then  notDominated2 is necessarily the complete list of favorites..Agda.Sorry, but you are dominated by that favorite..Agda!A list of incomparable favorites..AgdaGosh, got some pretty a here, compare with my current favorites! Discard it if there is already one that is better or equal. (Skewed conservatively: faithful to the old favorites.) If there is no match for it, add it, and dispose of all that are worse than a.We require a partial ordering. Less is better! (Maybe paradoxically.).AgdaCompare a new set of favorites to an old one and discard the new favorites that are dominated by the old ones and vice verse. (Skewed conservatively: faithful to the old favorites.) 'compareFavorites new old = (new', old').Agda)After comparing, do the actual insertion..Agda%Compare, then insert accordingly. :insert a l = insertCompared a l (compareWithFavorites a l).Agda=Insert all the favorites from the first list into the second..AgdaConstruct favorites from elements of a partial order. The result depends on the order of the list if it contains equal elements, since earlier seen elements are favored over later seen equals. The first element of the list is seen first..Agda. forms a  under  and 'union..AgdaEquality checking is a bit expensive, since we need to sort! Maybe use a Set! of favorites in the first place?................................  Safe-Inferred!!$%&.145789:;P .Agda,A finite map, represented as a set of pairs.%Invariant: at most one value per key..AgdaLookup keys in the same association list often. Use partially applied to create partial function apply m :: k -> Maybe v. First time:  O(n log n) in the worst case.Subsequently: O(log n).Specification:  apply m == (R m)..Agda9O(n). Get the domain (list of keys) of the finite map..AgdaO(1). Add a new binding. Assumes the binding is not yet in the list..AgdaO(n). Update the value at a key. The key must be in the domain of the finite map. Otherwise, an internal error is raised..AgdaO(n). Delete a binding. The key must be in the domain of the finite map. Otherwise, an internal error is raised..AgdaO(n). Update the value at a key with a certain function. The key must be in the domain of the finite map. Otherwise, an internal error is raised..AgdaMaps concrete module names to a list of abstract module names./AgdaAll abstract names targeted by a concrete name in scope. Computed by /./AgdaA local variable can be shadowed by an import. In case of reference to a shadowed variable, we want to report a scope error./AgdaUnique ID of local variable./Agda/Kind of binder used to introduce the variable (, let, ...)./AgdaIf this list is not empty, the local variable is shadowed by one or more imports./AgdaFor each bound variable, we want to know whether it was bound by a , , module telescope, pattern, or let./Agda (currently also used for  and module parameters)/Agda f ... =/Agda  let ... in/Agda  | ... in q/AgdaLocal variables./Agda"For the sake of highlighting, the / map also stores the . of an A.QName./AgdaThe ../Agda)Possible renderings of the abstract name./AgdaThe complete information about the scope at a particular program point includes the scope stack, the local variables, and the context precedence./AgdaThe variables that will be bound at the end of the current block of variables (i.e. clause). We collect them here instead of binding them immediately so we can avoid shadowing between variables in the same variable block./Agda&Maps concrete names C.Name to fixities/Agda(Maps concrete names C.Name to polarities/AgdaSee ./Agda#Things not exported by this module./Agda+Things defined and exported by this module./Agda1Things from open public, exported by this module./AgdaA scope is a named collection of names partitioned into public and private names./AgdaGet a / from /./Agda A lens for //Agda`Monadic' lens (Functor sufficient)./Agda3Shadow a local name by a non-empty list of imports./Agda1Treat patternBound variable as a module parameter/Agda*Project name of unshadowed local variable./Agda%Get all locals that are not shadowed  by imports./AgdaLenses for ScopeInfo components/Agda Lens for /./Agda Lens for /./Agda inNameSpace> selects either the name map or the module name map from a /. What is selected is determined by result type (using the dependent-type trickery)./Agda?For ambiguous constructors, we might have both alternatives of !. In this case, we default to ../Agda?For ambiguous constructors, we might have both alternatives of !. In this case, we default to ./Agda Only return  [Co]ConName if no ambiguity./AgdaVan Laarhoven lens on ../AgdaVan Laarhoven lens on ../AgdaThe empty name space./Agda9Map functions over the names and modules in a name space./AgdaZip together two name spaces./Agda&Map monadic function over a namespace./AgdaThe empty scope./AgdaThe empty scope info./Agda4Map functions over the names and modules in a scope./AgdaSame as /2 but applies the same function to all name spaces./AgdaSame as /7 but applies the function only on the given name space./Agda Maybe C.Name for defined names and module names. However, the penalty of doing it in two passes should not be too high. (Doubling the run time.)0Agda Version of 0 that also returns sets of name and module name clashes introduced by renaming0 to identifiers that are already imported by using or lack of hiding.0Agda%Rename the abstract names in a scope.0Agda%Remove private name space of a scope.Should be a right identity for /. >exportedNamesInScope . restrictPrivate == exportedNamesInScope.0Agda9Remove private things from the given module from a scope.0AgdaFilter privates out of a /0Agda3Disallow using generalized variables from the scope0Agda.Add an explanation to why things are in scope.0Agda5Get the public parts of the public modules of a scope0AgdaCompute a flattened scope. Only include unqualified names or names qualified by modules in the first argument.0Agda:Get all concrete names in scope. Includes bound variables.0AgdaLook up a name in the scope0AgdaFind the concrete names that map (uniquely) to a given abstract qualified name. Sort by number of modules in the qualified name, unqualified names first.0Agda A version of 0 that also delivers the .. Used in highlighting.0AgdaFind the concrete names that map (uniquely) to a given abstract module name. Sort by length, shortest first.0Agda+Add first string only if list is non-empty.0AgdaInvariant: the . components should be equal whenever we have to concrete renderings of an abstract name.0AgdaWe show shadowed variables as prefixed by a ".", as not in scope.0Agda/Sets the binding site of all names in the path..Agda. can be DefName, ., ...Agda(. ==) . . for all names..Agda isJust . / . . for all names..Agda(. ==) . . for all names.0Agda4Merged scope, clashing names, clashing module names.............................................///.........../////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////000000000000000000000000000000000///////////////////////////////////////////////////////////////////////////////////////.///...........///////....////.....................//........./////////////////////////000000...00000000000000000....00000000..00z Safe-Inferred!!$%&.145789:;1Agda:Has the constructor pattern a dotted (forced) constructor?1AgdaDotted constructor.1AgdaOrdinary constructor.1AgdaConstructor pattern info.1AgdaDoes this pattern come form the eta-expansion of an implicit pattern?1Agda;For a general pattern we remember the source code position.1AgdaThe range of the "as" and "to" keywords, if any. Retained for highlighting purposes.1AgdaThe "as" module name, if any. Retained for highlighting purposes.1Agda Retained for abstractToConcrete of &.1AgdaInformation about application1Agda6Do we prefer a lambda argument with or without parens?1Agda-Default is system inserted and prefer parens.1Agda1 with no range information.1AgdaSame as  mkDefInfo but where we can also give the  IsInstance1AgdaEmpty range for patterns.1AgdaDefault value for 1.>11111111111111111111111111111111111111111111111111111111111111>11111111111111111111111111111111111111111111111111111111111111{ Safe-Inferred!!$%&.145789:;12Agda#Conversion between different types.2AgdaA type that is intended to be used when constructing highlighting information.>Note the invariant which values of this type should satisfy (2).This is a type synonym in order to make it easy to change to another representation."The type should be an instance of " 2,  and &, and there should be an instance of 2 2 2.2AgdaHighlighting information.>Note the invariant which values of this type should satisfy (2).This is a type synonym in order to make it easy to change to another representation.2Agda'Highlighting info with delayed merging.Merging large sets of highlighting info repeatedly might be costly. The idea of this type is to accumulate small pieces of highlighting information, and then to merge them all at the end.>Note the invariant which values of this type should satisfy (2).2AgdaSyntax highlighting information, represented by maps from positions to 2.,The first position in the file has number 1.2AgdaA limited kind of syntax highlighting information: a pair consisting of " and 2.Note the invariant which 2s should satisfy (2).2AgdaIs the highlighting "token-based", i.e. based only on information from the lexer?2AgdaThe defining module.2AgdaThe file position in that module. File positions are counted from 1.2Agda Has this DefinitionSite/ been created at the defining site of the name?2Agda#A pretty name for the HTML linking.2AgdaMeta information which can be associated with a character/character range.2AgdaThis note, if not null, can be displayed as a tool-tip or something like that. It should contain useful information about the range (like the module containing a certain identifier, or the fixity of an operator).2AgdaThe definition site of the annotated thing, if applicable and known.2AgdaIs this entry token-based?2AgdaOther aspects, generated by type checking. (These can overlap with each other and with 2s.)2Agda.A warning that is considered fatal in the end.2AgdaUnsolved constraint not connected to meta-variable. This could for instance be an emptyness constraint.2AgdaUsed for highlighting unreachable clauses, unreachable RHS (because of an absurd pattern), etc.2Agda8Used for shadowed repeated variable names in telescopes.2AgdaWhen this constructor is used it is probably a good idea to include a 2* explaining why the pattern is incomplete.2Agda!Code which is being type-checked.2AgdaFunction declaration without matching definition NB: We put CatchallClause last so that it is overwritten by other, more important, aspects in the emacs mode.2AgdaNameKind(s are figured out during scope checking.2AgdaBound variable.2AgdaGeneralizable variable. (This includes generalizable variables that have been generalized).2Agda%Inductive or coinductive constructor.2Agda Record field.2Agda Module name.2Agda Primitive.2Agda Record type.2Agda!Named argument, like x in {x = v}2AgdaMacro.2Agda6Syntactic aspects of the code. (These cannot overlap.)2Agda Symbols like forall, =, ->, etc.2AgdaThings like Set and Prop.2AgdaIs the name an operator part?2AgdaText occurring in pragmas that does not have a more specific aspect.2Agda"Non-code contents in literate Agda2AgdaDelimiters used to separate the Agda code blocks from the other contents in literate Agda2AgdaInvariant for 2.2AgdaInvariant for 2 hl%, parametrised by the invariant for hl.?Additionally the endofunction should be extensionally equal to (fs ) for some list fs.2AgdaThe invariant for 2.2AgdaThe invariant for 2.?Additionally the endofunction should be extensionally equal to (fs ) for some list fs.3Agda A variant of  with 2 set to 2.3Agda4Conversion from classification of the scope checker.AgdaMerges meta information.3AgdaSome 2#s are more informative than others.3AgdaNameKind in Name can get more precise.""""""""2222222222222222222222222222222222222222222222222222222222222222222222222332222222222222222222222222222222222222222222222222222222222222222222222233""""""22""} Safe-Inferred!!$%&.145789:;R#AgdaTransposable things.3Agda3 m extracts the diagonal of m.For non-square matrices, the length of the diagonal is the minimum of the dimensions of the matrix.3Agda6Type of matrices, parameterised on the type of values.Sparse matrices are implemented as an ordered association list, mapping coordinates to values.3AgdaDimensions of the matrix.3Agda!Association of indices to values.3Agda%Type of matrix indices (row, column).3Agda Row index, 1 <= row <= rows.3Agda Column index 1 <= col <= cols.3AgdaSize of a matrix.3AgdaNumber of rows, >= 0.3AgdaNumber of columns, >= 0.3Agda~ iff the matrix is square.3AgdaReturns ~ iff the matrix is empty.3Agda5Compute the matrix size of the union of two matrices.Agda (i,)  $ f a), and same for gs and g.Agda Instance of 3$ which keeps longer assoc lists.  O(n1 + n2).3Agda?General pointwise combination function for sparse matrices.  O(n1 + n2).3Agda3 (+) m1 m2 adds m1 and m2, using (+) to add values.  O(n1 + n2).Returns a matrix of size 3 m1 m2.3Agda3 f m1 m2! build the pointwise conjunction m1 and m2 . Uses f to combine non-zero values.  O(n1 + n2).Returns a matrix of size  infSize m1 m2.3Agda"Association list intersection.  O(n1 + n2). interAssocWith f l l' = { (i, f a b) | (i,a) D l and (i,b) D l' }Used to combine sparse matrices, it might introduce zero elements if f( can return zero for non-zero arguments.3Agda3 semiring m1 m2 multiplies matrices m1 and m2). Uses the operations of the semiring semiring" to perform the multiplication.0O(n1 + n2 log n2 + (i <= r1) (j <= c2) d(i,j)) where r1$ is the number of non-empty rows in m1 and c2' is the number of non-empty columns in m2 and d(i,j) is the bigger one of the following two quantifies: the length of sparse row i in m1$ and the length of sparse column j in m2.Given dimensions  m1 : r1  c1 and  m2 : r2  c2, a matrix of size r1  c2* is returned. It is not necessary that c1 == r2, the matrices are implicitly patched with zeros to match up for multiplication. For sparse matrices, this patching is a no-op.3Agda3 x m adds a new column to m, after the columns already existing in the matrix. All elements in the new column get set to x.3Agda3 x m adds a new row to m, after the rows already existing in the matrix. All elements in the new row get set to x.3AgdaPointwise comparison. Only matrices with the same dimension are comparable.3AgdaDiagonal of sparse matrix.O(n) where n2 is the number of non-zero elements in the matrix.3AgdaMatrix transposition. O(n log n) where n2 is the number of non-zero elements in the matrix.3AgdaTransposing coordinates.3AgdaSize of transposed matrix.3AgdaOnly left map remaining.AgdaOnly right map remaining.Agda!Element only present in left map.Agda"Element only present in right map.AgdaElement present in both maps.Agda!Element only present in left map.Agda"Element only present in right map.AgdaElement present in both maps.3Agda$Element only present in left matrix.Agda%Element only present in right matrix.Agda!Element present in both matrices.AgdaResult counts as zero?33333333333333333333333333333333333333333333333333333333333333~ Safe-Inferred"!$%&.145789:;3AgdaA partial order, aimed at deciding whether a call graph gets worse during the completion.3Agda:In the paper referred to above, there is an order R with 4  Le  Lt.This is generalized to 4  'Decr k' where Decr 1 replaces Lt and Decr 0 replaces Le. A negative decrease means an increase. The generalization allows the termination checker to record an increase by 1 which can be compensated by a following decrease by 2 which results in an overall decrease.However, the termination checker of the paper itself terminates because there are only finitely many different call-matrices. To maintain termination of the terminator we set a cutoff point which determines how high the termination checker can count. This value should be set by a global or file-wise option.See Call for more information.9TODO: document orders which are call-matrices themselves.4Agda2Decrease of callee argument wrt. caller parameter.The Bool indicates whether the decrease (if any) is usable. In any chain, there needs to be one usable decrease. Unusable decreases come from SIZELT constraints which are not in inductive pattern match or a coinductive copattern match. See issue #2331.UPDATE: Andreas, 2017-07-26: Feature #2331 is unsound due to size quantification in terms. While the infrastructure for usable/unusable decrease remains in place, no unusable decreases are generated by TermCheck.4AgdaNo relation, infinite increase, or increase beyond termination depth.4Agda&Matrix-shaped order, currently UNUSED.4Agda$Raw increase which does not cut off.4Agda$Raw decrease which does not cut off.4AgdaSmart constructor for Decr k :: Order which cuts off too big values.Possible values for k:  - ?cutoff  k  ?cutoff + 1.4AgdaSmart constructor for matrix shaped orders, avoiding empty and singleton matrices.4Agdale, lt,  decreasing, unknown4: for backwards compatibility, and for external use.4AgdaUsable decrease.4AgdaDecreasing and usable?4AgdaMatrix-shaped order is decreasing if any diagonal element is decreasing.4AgdaMultiplication of 3.s. (Corresponds to sequential composition.)Agda collapse mWe assume that m codes a permutation: each row has at most one column that is not Unknown.To collapse a matrix into a single value, we take the best value of each column and multiply them. That means if one column is all Unknown, i.e., no argument relates to that parameter, then the collapsed value is also Unknown.,This makes order multiplication associative.Agda'Can two matrices be multplied together?4Agda+The supremum of a (possibly empty) list of 3;s. More information (i.e., more decrease) is bigger. 4# is no information, thus, smallest.Agda(3, , 4) forms a semiring, with 4 as zero and Le as one.4Agda%The infimum of a (non empty) list of 3$s. Gets the worst information. 4& is the least element, thus, dominant.AgdaPick the worst information.4AgdaWe use a record for semiring instead of a type class since implicit arguments cannot occur in instance constraints, like +instance (?cutoff :: Int) => SemiRing Order.4AgdaInformation order: 4 is least information. The more we decrease, the more information we have.When having comparable call-matrices, we keep the lesser one. Call graph completion works toward losing the good calls, tending towards Unknown (the least information).4Agda/We assume the matrices have the same dimension.4AgdaIt does not get worse then ` increase'. If we are still decreasing, it can get worse: less decreasing.3334444444444444444444434444444444444444444334 Safe-Inferred#!$%&.145789:;R4AgdaSets of incomparable call matrices augmented with path information. Use overloaded , , , .4Agda,Call matrix augmented with path information.4Agda"The matrix of the (composed call).4AgdaMeta info, like call path.4Agda0Call matrix multiplication and call combination.4AgdaCall matrices.A call matrix for a call f --> g has dimensions  ar(g)  ar(f).9Each column corresponds to one formal argument of caller f9. Each row corresponds to one argument in the call to g.In the presence of dot patterns, a call argument can be related to several different formal arguments of f. See e.g. testsucceedDotPatternTermination.agda:  data D : Nat -> Set where cz : D zero c1 : forall n -> D n -> D (suc n) c2 : forall n -> D n -> D n f : forall n -> D n -> Nat f .zero cz = zero f .(suc n) (c1 n d) = f n (c2 n d) f n (c2 .n d) = f n d 'Call matrices (without guardedness) are  -1 -1 n < suc n and n < c1 n d ? = c2 n d <= c1 n d = -1 n <= n and n < c2 n d ? -1 d < c2 n d Here is a part of the original documentation for call matrices (kept for historical reasons):This datatype encodes information about a single recursive function application. The columns of the call matrix stand for source function arguments (patterns). The rows of the matrix stand for target function arguments. Element (i, j)0 in the matrix should be computed as follows:4 (less than) if the j-th argument to the target; function is structurally strictly smaller than the i-th pattern.4 (less than or equal) if the j-th argument to the target+ function is structurally smaller than the i-th pattern.4 otherwise.4Agda0Call matrix indices = function argument indices.Machine integer ~ is sufficient, since we cannot index more arguments than we have addresses on our machine.4AgdaNon-augmented call matrix.4AgdaInsert into a call matrix set.4AgdaUnion two call matrix sets.4Agda/Convert into a list of augmented call matrices.4AgdaCall matrix multiplication.f --(m1)--> g --(m2)--> h is combined to f --(m2 3 m1)--> h9Note the reversed order of multiplication: The matrix c1 of the second call g-->h in the sequence  f-->g-->h is multiplied with the matrix c2 of the first call.Preconditions: m1 has dimensions  ar(g)  ar(f). m2 has dimensions  ar(h)  ar(g).Postcondition:  m1 >*< m2 has dimensions  ar(h)  ar(f).4Agda%Augmented call matrix multiplication.4Agda1Call matrix set product is the Cartesian product.444444444444444444444444444444444444 Safe-Inferred#!$%&.145789:;4AgdaA call graph is a set of calls. Every call also has some associated meta information, which should be al so that the meta information for different calls can be combined when the calls are combined.4AgdaCalls are edges in the call graph. It can be labelled with several call matrices if there are several pathes from one function to another.4AgdaCall graph nodes.Machine integer ~ is sufficient, since we cannot index more than we have addresses on our machine.4Agda!Make a call with a single matrix.4AgdaMake a call with empty cinfo.4AgdaReturns all the nodes with incoming edges. Somewhat expensive. O(e).4AgdaConverts a call graph to a list of calls with associated meta information.AgdaConverts a list of calls with associated meta information to a call graph.4Agda#Takes the union of two call graphs.4Agda!Inserts a call into a call graph.AgdaCall graph combination.Application of 4 to all pairs (c1,c2) for which $ c1 = $ c2.)4Agda"Call graph comparison. A graph cs' is `worse' than cs if it has a new edge (call) or a call got worse, which means that one of its elements that was better or equal to Le moved a step towards Un.A call graph is complete if combining it with itself does not make it any worse. This is sound because of monotonicity: By combining a graph with itself, it can only get worse, but if it does not get worse after one such step, it gets never any worse.4 cs completes the call graph cs. A call graph is complete if it contains all indirect calls; if f -> g and g -> h are present in the graph, then f -> h should also be present.4Agda?Displays the recursion behaviour corresponding to a call graph.4Agda4 is a monoid under 4.4Agda: checks whether the call graph is completely disconnected.$$4444444444444444444$$44444444444 Safe-Inferred"!$%&.145789:;҈4Agda2TODO: This comment seems to be partly out of date.4 cs( checks if the functions represented by cs terminate. The call graph cs should have one entry (4&) per recursive function application. perms: is returned if the functions are size-change terminating.,If termination can not be established, then  problems is returned instead. Here problems contains an indication of why termination cannot be established. See lexOrder for further details.Note that this function assumes that all data types are strictly positive.The termination criterion is taken from Jones et al. In the completed call graph, each idempotent call-matrix from a function to itself must have a decreasing argument. Idempotency is wrt. matrix multiplication.This criterion is strictly more liberal than searching for a lexicographic order (and easier to implement, but harder to justify).4AgdaA call c! is idempotent if it is an endo ($ == $) of order 1. (Endo-calls of higher orders are e.g. argument permutations). We can test idempotency by self-composition. Self-composition c >*< c: should not make any parameter-argument relation worse.44444444 Safe-Inferred!!$%&.145789:;4AgdaSometimes regular expressions aren't enough. Alex provides a way to do arbitrary computations to see if the input matches. This is done with a lex predicate.4AgdaIn the lexer, regular expressions are associated with lex actions who's task it is to construct the tokens.4Agda#This is what the lexer manipulates.4AgdaFile.4AgdaCurrent position.4AgdaCurrent input.4AgdaPreviously read character.4Agda A lens for 4.4Agda,Get the previously lexed character. Same as 4. Alex needs this to be defined to handle "patterns with a left-context".4Agda,Returns the next character, and updates the 4 value.This function is not suitable for use by Alex 2, because it can return non-ASCII characters.4Agda'Returns the next byte, and updates the 4 value.A trick is used to handle the fact that there are more than 256 Unicode code points. The function translates characters to bytes in the following way:Whitespace characters other than '\t' and '\n' are translated to ' '.8Non-ASCII alphabetical characters are translated to 'z'.;Other non-ASCII printable characters are translated to '+'.&Everything else is translated to '\1'.Note that it is important that there are no keywords containing 'z', '+', ' ' or '\1'.*This function is used by Alex (version 3).4AgdaConjunction of 4s.4AgdaDisjunction of 4s.4Agda Negation of 4s.44444444444444444444444444444444444444444444 Safe-Inferred!!$%&.145789:;ޢ 4AgdaThe LookAhead monad is basically a state monad keeping with an extra 4, wrapped around the ! monad.4Agda8Throw an error message according to the supplied method.4Agda$Get the current look-ahead position.5AgdaSet the look-ahead position.5AgdaLift a computation in the ! monad to the 4 monad.5AgdaLook at the next character. Fails if there are no more characters.Agda#Look at the next character. Return ~! if there are no more characters.5AgdaConsume all the characters up to the current look-ahead position.5Agda-Undo look-ahead. Restores the input from the !.5Agda!Consume the next character. Does 5 followed by 5.5AgdaDo a case on the current input string. If any of the given strings match we move past it and execute the corresponding action. If no string matches, we execute a default action, advancing the input one character. This function only affects the look-ahead position.5AgdaSame as 5 but takes the initial character from the first argument instead of reading it from the input. Consequently, in the default case the input is not advanced.5AgdaRun a 47 computation. The first argument is the error function. 444555555555 454455555555 Safe-Inferred!!$%&.145789:; 5AgdaLex a string literal. Assumes that a double quote has been lexed.5AgdaLex a character literal. Assumes that a single quote has been lexed. A character literal is lexed in exactly the same way as a string literal. Only before returning the token do we check that the lexed string is of length 1. This is maybe not the most efficient way of doing things, but on the other hand it will only be inefficient if there is a lexical error.AgdaCustom error function.AgdaThe general function to lex a string or character literal token. The character argument is the delimiter (" for strings and ' for characters).AgdaThis is where the work happens. The string argument is an accumulating parameter for the string being lexed.AgdaA string gap consists of whitespace (possibly including line breaks) enclosed in backslashes. The gap is not part of the resulting string.AgdaLex a single character.Agda?Lex an escaped character. Assumes the backslash has been lexed.Agda$Read a number in the specified base.AgdaSame as $ but with an accumulating parameter.AgdaThe escape codes.5555 Safe-Inferred!!$%&.145789:;R5Agda Should comment tokens be output?5Agda Should comment tokens be output?5Agda,Manually lexing a block comment. Assumes an  open comment< has been lexed. In the end the comment is discarded and 5" is called to lex a real token.5Agda Lex a hole ( {! ... !}#). Holes can be nested. Returns  .5AgdaSkip a block of text enclosed by the given open and close strings. Assumes the first open string has been consumed. Open-close pairs may be nested.5555555555 Safe-Inferred!!$%&.145789:;{5Agda Nat(Here the second line is not part of the where8 clause since it is has the same indentation as the data definition. What we have to do is insert an empty layout block {} after the where;. The only thing that can happen in this state is that 5 is executed, generating the closing brace. The open brace is generated when entering by 5.5AgdaThis state is entered at the beginning of each line. You can't lex anything in this state, and to exit you have to check the layout rule. Done with 5.5AgdaThis state can only be entered by the parser. In this state you can only lex the keywords using, hiding, renaming and to. Moreover they are only keywords in this particular state. The lexer will never enter this state by itself, that has to be done in the parser.5AgdaReturn the next token. This is the function used by Happy in the parser.  lexer k = 5 >>= kAgda&Do not use this function; it sets the ! to .5Agda3This is the main lexing function generated by Alex. 5555555555555 5555555555555 Safe-Inferred!!$%&.145789:;5AgdaAt a new line, we confirm either existing tentative layout columns, or, if the last token was a layout keyword, the expected new layout column.5Agda&This action is only executed from the 5/ state. It will exit this state, enter the 5 state, and return a virtual close brace (closing the empty layout block started by 5).5Agda ...)Agda+Converts lambda bindings to typed bindings.AgdaReturns the value of the first erasure attribute, if any, or else the default value of type .Raises warnings for all attributes except for erasure attributes, and for multiple erasure attributes.AgdaConstructs extended lambdas.Agda&Constructs extended or absurd lambdas.AgdaInterpret an expression as a list of names and (not parsed yet) as-patternsAgda0Match a pattern-matching "assignment" statement p <- eAgdaBuild a with-blockAgdaBuild a with-statementAgdaBuild a do-statementAgdaExtract record directivesAgda&Check for duplicate record directives.5AgdaBreaks up a string into substrings. Returns every maximal subsequence of zero or more characters distinct from . splitOnDots "" == [""] splitOnDots "foo.bar" == ["foo", "bar"] splitOnDots ".foo.bar" == ["", "foo", "bar"] splitOnDots "foo.bar." == ["foo", "bar", ""] splitOnDots "foo..bar" == ["foo", "", "bar"]AgdaReturns ~= iff the name is a valid Haskell (hierarchical) module name.Agda)Turn an expression into a left hand side.AgdaTurn an expression into a pattern. Fails if the expression is not a valid pattern.AgdaTurn an expression into a name. Fails if the expression is not a valid identifier.AgdaWhen given expression is e1 = e2, turn it into a named expression. Call this inside an implicit argument {e} or {{e}}, where an equality must be a named argument (rather than a cubical partial match).AgdaParse an attribute.Agda%Apply an attribute to thing (usually ). This will fail if one of the attributes is already set in the thing to something else than the default value.Agda#Apply attributes to thing (usually ). Expects a reversed list of attributes. This will fail if one of the attributes is already set in the thing to something else than the default value.Agda$Set the tactic attribute of a binderAgda$Get the tactic attribute if present.AgdaReport a parse error if two attributes in the list are of the same kind, thus, present conflicting information.AgdaReport an attribute as conflicting (e.g., with an already set value).AgdaReport attributes as conflicting (e.g., with each other). Precondition: List not emtpy.Agda!The attributes, in reverse order.Agda#The range of the lambda symbol and where or the braces.Agda The attributes in reverse order.AgdaThe clauses in reverse order.AgdaThe range of the lambda symbol.Agda!The attributes, in reverse order.Agda Catch-all?Agda Possibly empty list of patterns.555555555555559 9  Safe-Inferred!!$%&.145789:;-5AgdaWrapped Parser type.5Agda/A monad for handling parse errors and warnings.5AgdaRun a 5 computation, returning a list of warnings in first-to-last order and either a parse error or the parsed thing.AgdaAdd a !.AgdaEmbed a ! as 5 computation.5Agda'Returns the contents of the given file.AgdaInitial state for lexing.Agda/Initial state for lexing with top-level layout.5AgdaParse without top-level layout.AgdaParse with top-level layout.AgdaParse with top-level layout.€AgdaParse with top-level layout.5AgdaExtensions supported by 5.5AgdaParses a module.5AgdaParses a module name.5AgdaParses an expression.5Agda0Parses an expression followed by a where clause.5AgdaParses an expression or some other content of an interaction hole.5Agda3Gives the parsed token stream (including comments).ÀAgda9Keep comments in the token stream generated by the lexer.ĀAgdaDo not keep comments in the token stream generated by the lexer.AgdaName of source file.AgdaParser to use.AgdaContents of source file.ŀAgdaThe path to the file.Agda)The file contents. Note that the file is not read from disk.5AgdaThe path to the file.Agda)The file contents. Note that the file is not read from disk.#!!!!!!!!!!!!!!!!!!!5555555555555555#555555555555!!!!!!!!!!!!!!!!!!!5555 Safe-Inferred!!$%&.145789:;R 5Agda5Eliminations, subsuming applications and projections.5Agda Application.5Agda Projection.  is name of a record projection.5Agda'IApply x y r, x and y are the endpoints5AgdaDrop 5 constructor. (Safe)5AgdaDrop 5 constructors. (Safe)5AgdaSplit at first non-55Agda Discards Proj f entries.5AgdaDrop 5 constructors. (Safe)5AgdaThis instance cheats on 5, use with care. 5s are always assumed to be , since they have no . Same for IApply 555555555555 555555555555 Safe-Inferred!!$%&.145789:;! 5AgdaShould a constraint wake up or not? If not, we might refine the unblocker.5AgdaSomething where a meta variable may block reduction. Notably a top-level meta is considered blocking. This did not use to be the case (pre Aug 2020).5AgdaWhat is causing the blocking? Or in other words which metas or problems need to be solved to unblock the blocked computation/constraint.5AgdaUnblock if meta is instantiated6AgdaEven if we are not stuck on a meta during reduction we can fail to reduce a definition by pattern matching for another reason.6AgdaThe Elim' is neutral and blocks a pattern match.6AgdaA level is a maximum expression of a closed level and 0..n 74 expressions each of which is an atom plus a number.7AgdaSorts.7AgdaSet B.7AgdaProp B.7AgdaSet:.7AgdaSSet B.7AgdaSizeUniv, a sort inhabited by type Size.7AgdaLockUniv, a sort for locks.7AgdaSort of the pi type.7Agda(Sort of a (non-dependent) function type.7AgdaSort of another sort.7AgdaA postulated sort.7AgdaA (part of a) term or type which is only used for internal purposes. Replaces the abuse of Prop for a dummy sort. The String typically describes the location where we create this dummy, but can contain other information as well.7AgdaSequence of types. An argument of the first type is bound in later types and so on.7Agda7 is never 7.7Agda'Types are terms with a sort annotation.7AgdaBinder.72: The bound variable might appear in the body. 7 is pseudo-binder, it does not introduce a fresh variable, similar to the const of Haskell.7Agda6The body has (at least) one free variable. Danger: 7! doesn't shift variables properly7Agda Raw values.Def is used for both defined and undefined constants. Assume there is a type declaration and a definition for every constant, even if the definition is an empty list of clauses.7Agdax es neutral7Agda+Terms are beta normal. Relevance is ignored7Agdaf es, possibly a delta/iota-redex7Agdac es or record { fs = es } es allows only Apply and IApply eliminations, and IApply only for data constructors.7Agda)dependent or non-dependent function space7AgdaIrrelevant stuff in relevant position, but created in an irrelevant context. Basically, an internal version of the irrelevance axiom .irrAx : .A -> A.7AgdaA (part of a) term or type which is only used for internal purposes. Replaces the  Sort Prop hack. The String typically describes the location where we create this dummy, but can contain other information as well. The second field accumulates eliminations in case we apply a dummy term to more of them. Dummy terms should never be used in places where they can affect type checking, so syntactic checks are free to ignore the eliminators, which are only there to ease debugging when a dummy term incorrectly leaks into a relevant position.7AgdaStore the names of the record fields in the constructor. This allows reduction of projection redexes outside of TCM. For instance, during substitution and application.7AgdaThe name of the constructor.7AgdaData or record constructor?7Agda'Record constructors can be coinductive.7Agda"The name of the record fields.  is stored since the info in the constructor args might not be accurate because of subtyping (issue #2170).7AgdaType of argument lists.7Agda Similar to , but we need to distinguish an irrelevance annotation in a function domain (the domain itself is not irrelevant!) from an irrelevant argument.Dom is used in 7 of internal syntax, in Context and 7.  is used for actual arguments (7, 7, 7 etc.) and in Abstract syntax and other situations.  cubical When domFinite = True for the domain of a 7 type, the elements should be compared by tabulating the domain type. Only supported in case the domain type is primIsOne, to obtain the correct equality for partial elements.7Agdae.g. x in {x = y : A} -> B.7Agda "@tactic e".7AgdaConstant level n8Agda6Make an absurd pattern with the given de Bruijn index.8AgdaBuild partial 6 from 78AgdaBuild 7 from 6.8Agda'Retrieve the PatternInfo from a pattern8Agda Retrieve the origin of a pattern8Agda1Does the pattern perform a match that could fail?8AgdaAbsurd lambdas are internally represented as identity with variable name "()".8AgdaAn unapplied variable.8AgdaAdd 7 is it is not already a DontCare.8AgdaConstruct a string representing the call-site that created the dummy thing.8Agda,Aux: A dummy term to constitute a dummy termlevel sort/type.8AgdaA dummy level to constitute a level/sort created at location. Note: use macro  DUMMY_LEVEL !8Agda5A dummy term created at location. Note: use macro  DUMMY_TERM !8Agda5A dummy sort created at location. Note: use macro  DUMMY_SORT !8Agda5A dummy type created at location. Note: use macro  DUMMY_TYPE !8AgdaContext entries without a type have this dummy type. Note: use macro  DUMMY_DOM !8AgdaGiven a constant m and level l , compute m + l8Agda)A traversal for the names in a telescope.8Agda(Convert a list telescope to a telescope.8Agda%Convert a telescope to its list form.8AgdaLens to edit a 7 as a list.8AgdaRemoving a topmost 7 constructor.8AgdaDoesn't do any reduction.8Agda>Convert top-level postfix projections into prefix projections.8AgdaConvert 5/ projection eliminations according to their  into 7 projection applications.8Agda#A view distinguishing the neutrals Var, Def, and MetaV which can be projected.8AgdaIgnores  and  and tactic.8Agda2The size of a telescope is its length (as a list).9AgdaA  clause is one with no patterns and no rhs. Should not exist in practice.6AgdaThe  PatVarName is a name suggestion.7Agda#eliminations ordered left-to-right.8Agda-Should absurd patterns count as proper match?Agda1Should projection patterns count as proper match?Agda The pattern.555555555555555555555555556666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666777666677777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777888888888888888888888888888888888888888888888888888888888888886666666666666666666666666666666666666666666666666666666666666666667776666777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777778888888888888888888888888888888888888888888888888888888888888864 Safe-Inferred!!$%&.145789:;\9AgdaThings we can substitute for a variable. Needs to be able to represent variables, e.g. for substituting under binders.9Agda+Produce a variable without name suggestion.9Agda(Produce a variable with name suggestion.9Agda=Are we dealing with a variable? If yes, what is its index?9AgdaWe can substitute Terms for variables.99999999 Safe-Inferred!!$%&.145789:;]99999999 Safe-Inferred!!$%&.145789:;s.:Agda&Gather free variables in a collection.:AgdaThe current context.:AgdaAdditional context, e.g., whether to ignore free variables in sorts.:AgdaAre we flexible or rigid?:Agda+What is the current relevance and quantity?:Agda#Method to return a single variable.:Agda5Where should we skip sorts in free variable analysis?:Agda Do not skip.:AgdaSkip when annotation to a type.:AgdaSkip unconditionally.:AgdaKeep track of :7 for every variable, but forget the involved meta vars.:AgdaRepresentation of a variable set as map from de Bruijn indices to :.:AgdaAny representation c of a set of variables need to be able to be modified by a variable occurrence. This is to ensure that free variable analysis is compositional. For instance, it should be possible to compute `fv (v [u/x])` from `fv v` and `fv u`.)In algebraic terminology, a variable set a; needs to be (almost) a left semimodule to the semiring :.:AgdaLaws * Respects monoid operations: ``` withVarOcc o mempty == mempty withVarOcc o (x <> y) == withVarOcc o x <> withVarOcc o y ``` * Respects VarOcc composition: ``` withVarOcc oneVarOcc = id withVarOcc (composeVarOcc o1 o2) = withVarOcc o1 . withVarOcc o2 ``` * Respects VarOcc aggregation: ``` withVarOcc (o1 <> o2) x = withVarOcc o1 x <> withVarOcc o2 x ``` Since the corresponding unit law may fail, ``` withVarOcc mempty x = mempty ``` it is not quite a semimodule.:AgdaOccurrence of free variables is classified by several dimensions. Currently, we have : and .:AgdaDepending on the surrounding context of a variable, it's occurrence can be classified as flexible or rigid, with finer distinctions.The constructors are listed in increasing order (wrt. information content).:Agda7In arguments of metas. The set of metas is used by ' to generate the right blocking information. The semantics is that the status of a variable occurrence may change if one of the metas in the set gets solved. We may say the occurrence is tainted by the meta variables in the set.:Agda*In arguments to variables and definitions.:AgdaIn top position, or only under inductive record constructors (unit).:Agda3Under at least one and only inductive constructors.:Agda5A set of meta variables. Forms a monoid under union.:Agda: aggregation (additive operation of the semiring). For combining occurrences of the same variable in subterms. This is a refinement of the  operation for : which would work if : did not have the :* as an argument. Now, to aggregate two :$ occurrences, we union the involved :s.:Agda Unit for :.:AgdaAbsorptive for :.:Agda: composition (multiplicative operation of the semiring). For accumulating the context of a variable.: is dominant. Once we are under a meta, we are flexible regardless what else comes. We taint all variable occurrences under a meta by this meta.:0 is next in strength. Destroys strong rigidity.: is still dominant over :.:0 is the unit. It is the top (identity) context.:Agda Unit for :.:AgdaThe absorptive element of variable occurrence under aggregation: strongly rigid, relevant.:AgdaFirst argument is the outer occurrence (context) and second is the inner. This multiplicative operation is to modify an occurrence under a context.:AgdaIgnore free variables in sorts.:AgdaThe initial context.:AgdaRun function for FreeM.:AgdaBase case: a variable.:Agda3Subtract, but return Nothing if result is negative.:AgdaGoing under a binder.:Agda Going under n binders.:Agda Changing the .:Agda Changing the .:Agda Changing the : context.:Agda v[args].;AgdaApply something to a bunch of arguments. Preserves blocking tags (application can never resolve blocking).;Agda Apply to some default arguments.;Agda#Apply to a single default argument.;Agda%Raise de Bruijn index, i.e. weakening;AgdaReplace de Bruijn index i by a 7 in something.;AgdaReplace what is now de Bruijn index 0, but go under n binders. %substUnder n u == subst n (raise n u).;AgdaTo replace index n by term u, do applySubst (singletonS n u).  ,  E u : A --------------------------------- ,  E singletonS || u : , A,  ;AgdaSingle substitution without disturbing any deBruijn indices.  , A,  E u : A --------------------------------- , A,  E inplace || u : , A,  ;Agda$Lift a substitution under k binders.;Agda   E  : ,  -------------------  E dropS ||  :  ;Agda applySubst ( ;& ) v == applySubst  (applySubst  v);Agda   E  :   E reverse vs :  ----------------------------- (treating Nothing as having any type)  E prependS vs  : ,  ;Agda E (strengthenS E ||) : ,;AgdalookupS (listS [(x0,t0)..(xn,tn)]) xi = ti, assuming x0 < .. < xn.;Agda #, ,  E raiseFromS || || : , ;Agda/Instantiate an abstraction. Strict in the term.;AgdaInstantiate an abstraction. Lazy in the term, which allow it to be  IMPOSSIBLE in the case where the variable shouldn't be used but we cannot use ;. Used in Apply.;Agda9Instantiate an abstraction that doesn't use its argument.;AgdaunderAbs k a b applies k to a# and the content of abstraction b# and puts the abstraction back. a is raised if abstraction was proper such that at point of application of k and the content of b. are at the same context. Precondition: a and b& are at the same context at call time.;AgdaunderLambdas n k a b drops n initial 7s from b, performs operation k on a and the body of b, and puts the 7 s back. a is raised correctly according to the number of abstractions.,;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;,;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;4 Safe-Inferred!!$%&.145789:;/;;;;;;;;;;;;;;;;;;;;;;;;;;;;;<<<;<;<<;;<<<<<<< State [i] (f (Pattern' (i,x)))<Agda+Arity of a function, computed from clauses.<AgdaTranslate the clause patterns to terms with free variables bound by the clause telescope.%Precondition: no projection patterns.<AgdaTranslate the clause patterns to an elimination spine with free variables bound by the clause telescope.<Agda5Augment pattern variables with their de Bruijn index.<AgdaComputes the permutation from the clause telescope to the pattern variables.Use as  fromMaybe  IMPOSSIBLE . dbPatPerm to crash in a controlled way if a de Bruijn index is out of scope here.The first argument controls whether dot patterns counts as variables or not.<AgdaComputes the permutation from the clause telescope to the pattern variables.Use as  fromMaybe  IMPOSSIBLE . clausePerm to crash in a controlled way if a de Bruijn index is out of scope here.<AgdaTurn a pattern into a term. Projection patterns are turned into projection eliminations, other patterns into apply elimination.<AgdaCompute from each subpattern a value and collect them all in a monoid.<AgdaTraverse pattern(s) with a modification before the recursive descent.<AgdaTraverse pattern(s) with a modification after the recursive descent.<Agda!Get the number of common initial 5 patterns in a list of clauses.<AgdaGet the number of initial 5 patterns in a clause.<AgdaGet the number of initial 5 patterns.<AgdaModify the content of VarP, and the closest surrounding NamedArg. Note: the  mapNamedArg for Pattern'! is not expressible simply by fmap or traverse etc., since ConP has NamedArg1 subpatterns, which are taken into account by  mapNamedArg.<Agda>Combine a pattern and the value computed from its subpatterns.<Agdapre : Modification before recursion.Agdapost: Modification after recursion.<Agdapre : Modification before recursion.<Agdapost: Modification after recursion.<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< Safe-Inferred"!$%&.145789:;<AgdaGeneric term traversal.Note: ignores sorts in terms! (Does not traverse into or collect from them.)<Agda?Generic traversal with post-traversal action. Ignores sorts.<AgdaGeneric fold, ignoring sorts.<Agda5Put it in a monad to make it possible to do strictly.<<<<<<<< Safe-Inferred!!$%&.145789:;<AgdaCase tree with bodies.<Agda Case n bs stands for a match on the n(-th argument (counting from zero) with bs as the case branches. If the n+-th argument is a projection, we have only < with arity 0.<Agda Done xs b stands for the body b where the xs contains hiding and name suggestions for the free variables. This is needed to build lambdas on the right hand side for partial applications which can still reduce.<AgdaAbsurd case. Add the free variables here as well so we can build correct number of lambdas for strict backends. (#4280)<AgdaBranches in a case tree.<Agda3We are constructing a record here (copatterns). < lists projections.<AgdaMap from constructor (or projection) names to their arity and the case subtree. (Projections have arity 0.)<AgdaEta-expand with the given (eta record) constructor. If this is present, there should not be any conBranches or litBranches.<Agda!Map from literal to case subtree.<Agda'(Possibly additional) catch-all clause.<Agda?(if True) In case of non-canonical argument use catchAllBranch.<AgdaLazy pattern match. Requires single (non-copattern) branch with no lit branches and no catch-all.<AgdaCheck that the requirements on lazy matching (single inductive case) are met, and set lazy to False otherwise.<Agda1Check whether a case tree has a catch-all clause.<Agda5Check whether a case tree has any projection patterns<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< Safe-Inferred!!$%&.145789:;A=AgdaReturns every meta-variable occurrence in the given type, except for those in sort annotations on types.=AgdaReturns = in a list. allMetasList = allMetas (:[]).Note: this resulting list is computed via difference lists. Thus, use this function if you actually need the whole list of metas. Otherwise, use = with a suitable monoid.=Agda~ if thing contains no metas. noMetas = null . allMetasList.=Agda8Returns the first meta it find in the thing, if any. 'firstMeta == listToMaybe . allMetasList.=AgdaA blocker that unblocks if any of the metas in a term are solved.=AgdaA blocker that unblocks if any of the metas in a term are solved.================ Safe-Inferred!!$%&.145789:;=AgdaGetting the used definitions.Note: in contrast to  getDefs also collects from sorts in terms. Thus, this is not an instance of foldTerm.=Agda*What it takes to get the used definitions.=AgdaInputs to and outputs of getDefs' are organized as a monad.=AgdagetDefs' lookup emb a extracts all used definitions (functions, data/record types) from a, embedded into a monoid via emb7. Instantiations of meta variables are obtained via lookup."Typical monoid instances would be [QName] or  Set QName. Note that emb can also choose to discard a used definition by mapping to the unit of the monoid. =========== =========== Safe-Inferred!!$%&.145789:;Ǚ=AgdaTurn a name into an expression.=AgdaAre we in an abstract block?)In that case some definition is abstract.=Agda,Parameterised over the type of dot patterns.=AgdaDestructor pattern d.=Agda%Defined pattern: function definition f ps. It is also abused to convert destructor patterns into concrete syntax thus, we put AmbiguousQName here as well.=AgdaUnderscore pattern entered by user. Or generated at type checking for implicit arguments.=Agda Dot pattern .e=Agda| p, for with-patterns.=AgdaPattern with type annotation=AgdaThe lhs in projection-application and with-pattern view. Parameterised over the type e of dot patterns.=Agda&The head applied to ordinary patterns.=Agda Projection.=AgdaWith patterns.=AgdaHead f.=AgdaApplied to patterns ps.=AgdaRecord projection identifier.=AgdaMain argument of projection.=Agda E.g. the =.=AgdaApplied to with patterns | p1 | ... | pn*. These patterns are not prefixed with WithP!=AgdaThe lhs of a clause in focused (projection-application) view (outside-in). Projection patters are represented as =s.=AgdaRange.=Agda Copatterns.=AgdaThe lhs of a clause in spine view (inside-out). Projection patterns are contained in  spLhsPats, represented as ProjP d.=AgdaRange.=Agda!Name of function we are defining.=Agda3Elimination by pattern, projections, with-patterns.>AgdaThe " is the name of the with function.>AgdaWe store the original concrete expression in case we have to reproduce it during interactive case splitting. ~ for internally generated rhss.>AgdaThe s are the names of the generated with functions, one for each >.>AgdaThe patterns stripped by with-desugaring. These are only present if this rewrite follows a with.>AgdaThe RHS should not be another  RewriteRHS.>Agda&The where clauses are attached to the  RewriteRHS by>AgdaThe declaration is a >.>AgdaWe could throw away where0 clauses at this point and translate them to let,. It's not obvious how to remember that the let was really a where6 clause though, so for the time being we keep it here.>AgdaOnly in with-clauses where we inherit some already checked patterns from the parent. These live in the context of the parent clause left-hand side.>AgdaA user pattern together with an internal term that it should be equal to after splitting is complete. Special cases: * User pattern is a variable but internal term isn't: this will be turned into an as pattern. * User pattern is a dot pattern: this pattern won't trigger any splitting but will be checked for equality after all splitting is complete and as patterns have been bound. * User pattern is an absurd pattern: emptiness of the type will be checked after splitting is complete. * User pattern is an annotated wildcard: type annotation will be checked after splitting is complete.>AgdaWe don't yet know the position of generalized parameters from the data sig, so we keep these in a set on the side.>AgdaMaps generalize variables to the corresponding bound variable (to be introduced by the generalisation).>AgdaA typed binding. Appears in dependent function spaces, typed lambdas, and telescopes. It might be tempting to simplify this to only bind a single name at a time, and translate, say,  (x y : A) to (x : A)(y : A) before type-checking. However, this would be slightly problematic: $We would have to typecheck the type A several times.If A contains a meta variable or hole, it would be duplicated by such a translation.While 1. is only slightly inefficient, 2. would be an outright bug. Duplicating A could not be done naively, we would have to make sure that the metas of the copy are aliases of the metas of the original.>AgdaAs in telescope  (x y z : A) or type (x y z : A) -> B.>AgdaE.g.  (let x = e) or  (let open M).>Agda0A lambda binding is either domain free or typed.>Agda. x or {x} or .x or {x = y} or x@p or (p)>Agda. (xs:e) or {xs:e} or (let Ds)>AgdaOnly >s.>AgdaBindings that are valid in a let.>Agda LetBind info rel name type defn>AgdaIrrefutable pattern binding.>Agda*LetApply mi newM (oldM args) renamings dir. The ImportDirective is for highlighting purposes.>Agda,only for highlighting and abstractToConcrete>Agda?Only used for highlighting. Refers to the first occurrence of x in let x : A; x = e(. | LetGeneralize DefInfo ArgInfo Expr>Agda. is not .:. Name can be ambiguous e.g. for built-in constructors.>AgdaBuiltins that do not come with a definition, but declare a name for an Agda concept.>Agda"Range is range of REWRITE keyword.>Agda:For coinductive records, use pragma instead of regular  eta-equality, definition (as it is might make Agda loop).>Agda tel. M args : applies M to args and abstracts tel.>Agda  M {{...}}>Agda3Type signature (can be irrelevant, but not hidden).The fourth argument contains an optional assignment of polarities to arguments.>AgdaFirst argument is set of generalizable variables used in the type.>Agda record field>Agdaprimitive function>Agda)a bunch of mutually recursive definitions>AgdaThe ImportDirective is for highlighting purposes.>AgdaThe ImportDirective is for highlighting purposes.>Agda'only retained for highlighting purposes>Agdasequence of function clauses>Agdalone data signature>Agdalone record signature>AgdaThe >' gives the constructor type telescope, (x1 : A1)..(xn : An) -> Prop, and the optional name is the constructor's name. The optional   is for the pattern attribute.>AgdaOnly for highlighting purposes>Agdascope annotation>AgdaRenaming (generic).>AgdaRecord field assignment f = e.>AgdaExpressions after scope checking (operators parsed, names resolved).>AgdaBound variable.>AgdaConstant: axiom, function, data or record type, with a possible suffix.>AgdaProjection (overloaded).>AgdaConstructor (overloaded).>AgdaPattern synonym.>AgdaMacro.>AgdaLiteral.>Agda&Meta variable for interaction. The " is usually identical with the 1 of 1. However, if you want to print an interaction meta as just ? instead of ?n, you should set the 1 to ~ while keeping the .>Agda=Meta variable for hidden argument (must be inferred locally).>Agda.e, for postfix projection.>AgdaOrdinary (binary) application.>AgdaWith application.>Agda bs C e.>Agda() or {}.>AgdaDependent function space  C A.?Agda(Like a Pi, but the ordering is not known?AgdaNon-dependent function space.?Agda let bs in e.?Agda#Only used when printing telescopes.?AgdaRecord construction.?AgdaRecord update.?AgdaScope annotation.?AgdaQuote an identifier .?Agda Quote a term.?Agda#The splicing construct: unquote ...?Agda For printing DontCare from Syntax.Internal.?AgdaA name in a binding position: we also compare the nameConcrete when comparing the binders for equality.With  --caching on we compare abstract syntax to determine if we can reuse previous typechecking results: during that comparison two names can have the same nameId but be semantically different, e.g. in  {_ : A} -> .. vs.  {r : A} -> ...?AgdaPattern synonym for regular Def?Agda!Smart constructor for Generalized?Agda$The name defined by the given axiom.3Precondition: The declaration has to be a (scoped) >.?AgdaDoes not compare / fields.?AgdaDoes not compare / fields. Does not distinguish between prefix and postfix projections.?AgdaIgnore   when comparing =s.?AgdaIgnore > when comparing >s.?AgdaTurn a . into an expression.Assumes name is not ..?AgdaTurn an . into an expression.================================================>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>?>>>>??????>>>>>>>?>?>>??>>???????????????????????================================================>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>?>>>>??????>>>>>>>?>?>>??>>??????????????????????? Safe-Inferred!!$%&.145789:;:@Agda-Extracts "all" names which are declared in a >.Includes: local modules and where clauses. Excludes:  open public, let, with" function names, extended lambdas.@AgdaApply an expression rewriting to every subexpression, inside-out. See Agda.Syntax.Internal.Generic.@AgdaThe first expression is pre-traversal, the second one post-traversal.@AgdaCollects plain lambdas.@Agda-Gather applications to expose head and spine.Note: everything is an application, possibly of itself to 0 arguments@AgdaGather top-level = atterns and =%atterns to expose underlying pattern.@Agda Remove top ? wrappers.@AgdaRemove ? wrappers everywhere.!NB: Unless the implementation of @ for clauses has been finished, this does not work for clauses yet.@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ Safe-Inferred!!$%&.145789:;&AAgdaMerge a list of pattern synonym definitions. Fails unless all definitions have the same shape (i.e. equal up to renaming of variables and constructor names).AAgda.Match an expression against a pattern synonym.AAgda*Match a pattern against a pattern synonym.AAAAAA Safe-Inferred!!$%&.145789:;_AAgda-Convert a focused lhs to spine view and back.AAgdaThe next patterns are ...(This view discards 1.)AAgda&Application patterns (non-empty list).AAgda6A projection pattern. Is also stored unmodified here.AAgdaWith patterns (non-empty list). These patterns are not prefixed with =.AAgdaGeneric pattern traversal.AAgda Fold pattern.AAgdaTraverse pattern.AAgdaCompute from each subpattern a value and collect them all in a monoid.AAgdaTraverse pattern(s) with a modification before the recursive descent.AAgdaTraverse pattern(s) with a modification after the recursive descent.AAgda?Map pattern(s) with a modification after the recursive descent.AAgda9Collect pattern variables in left-to-right textual order.AAgda4Check if a pattern contains a specific (sub)pattern.AAgdaCheck if a pattern contains an absurd pattern. For instance, suc () , does so.+Precondition: contains no pattern synonyms.AAgda)Check if a pattern contains an @-pattern.AAgdaCheck if any user-written pattern variables occur more than once, and throw the given error if they do.AAgdaPattern substitution.For the embedded expression, the given pattern substitution is turned into an expression substitution.AAgdaPattern substitution, parametrized by substitution function for embedded expressions.AAgda7Split patterns into (patterns, trailing with-patterns).AAgda1Get the tail of with-patterns of a pattern spine.AAgdaConstruct the A" of the given list (if not empty).+Return the view and the remaining patterns.AAgdaAdd applicative patterns (non-projection / non-with patterns) to the right.AAgdaAdd with-patterns to the right.AAgdaCombine a pattern and the value computed from its subpatterns.AAgdapre : Modification before recursion.Agdapost: Modification after recursion.AAgdapre : Modification before recursion.AAgdapost: Modification after recursion.AAgda&Substitution function for expressions.Agda(Parallel) substitution.AgdaInput pattern.%AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA%AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA Safe-Inferred'!$%&()./0145789:;AAgda Currying as b# witnesses the isomorphism between  Arrows as b and Products as -> b. It is defined as a type class rather than by recursion on a singleton for as so all of that these conversions are inlined at compile time for concrete arguments.AAgdaUsing IsBase we can define notions of Domains and  CoDomains. which *reduce* under positive information IsBase t ~ 'True even though the shape of t is not formally exposedAAgdaIsBase t is 'True whenever t is *not* a function space.AAgdaArrows [a1,..,an] r corresponds to a1 -> .. -> an -> r | Products [a1,..,an] corresponds to (a1, (..,( an, ())..))AAgda Version of Foldr taking a defunctionalised argument so that we can use partially applied functions.AAgdaOn ListsAAgda On BooleansAAgdaAll p as ensures that the constraint p is satisfied by all the types in as. (Types is between scare-quotes here because the code is actually kind polymorphic)AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA Safe-Inferred$!$%&().0145789:;AAgdaA known boolean is one we can obtain a singleton for. Concrete values are trivially known.AAgda"Singleton for type level booleans.AAAAAAAAAAAAAA Safe-Inferred!!$%&.145789:;AAgdaLike  Bifunctor, but preserving sharing.AAgdaLike ~, but preserving sharing.AAgdaThe ChangeT monad transformer.AAgdaThe class of change monads.BAgdaRun a A0 computation, returning result plus change flag.ɀAgdaRun a A% computation, but ignore change flag.BAgdaMap a A( computation (monad transformer action).BAgdaBlindly run an updater.BAgdaRun a A0 computation, returning result plus change flag.BAgdaBlindly run an updater.BAgdaMark a computation as dirty.BAgdaReplace result of updating with original input if nothing has changed.ʀAgdaEval an updater (using B).BAgda8A mock change monad. Always assume change has happened.AAgda = sharing . updater1AAgda-Mark computation as having changed something.AAAAAAAAAAAAAAABBBBBBBBABBABAAAABABBBBAAAAAAAA Safe-Inferred#!$%&().145789:;cˀAgdaMake a declaration private.*Andreas, 2012-11-17: Mark computation as B if there was a declaration that could be privatized. If no privatization is taking place, we want to complain about -."Alternatively, we could only flag B6 if a non-private thing was privatized. Then, nested private+s would sometimes also be complained about.̀AgdaMake a declaration abstract.Mark computation as B if there was a declaration that could be made abstract. If no abstraction is taking place, we want to complain about -."Alternatively, we could only flag B7 if a non-abstract thing was abstracted. Then, nested abstract+s would sometimes also be complained about.̀AgdaCheck that declarations in a mutual block are consistently equipped with MEASURE pragmas, or whether there is a NO_TERMINATION_CHECK pragma.΀Agda Replace (DataRecFun)Sigs with Axioms for postulated names The first argument is a list of axioms only.BAgdaMain. Fixities (or more precisely syntax declarations) are needed when grouping function clauses.BAgda(Approximately) convert a , back to a list of &s.BAgdaHas the , a field of type ?BAgdaContents of a where& clause are abstract if the parent is.΀Agda(Lone signatures to be turned into AxiomsAgdaDeclarations containing themAgda+In the output, everything should be defined,,,,,,,,,,,,,,,,,,,,,,,,,,,----------------------------------------------BBB,,,,,,,,,,,,,,,,,,,,,,,,,,---------------------------------------------BBB,- Safe-Inferred!!$%&.145789:;fghijklmnopqrBBBgflprjohimknqB Safe-Inferred!!$%&.145789:;BAgda e.g. x + 5BAgdaa number or infinityBAgdaA solution assigns to each flexible variable a size expression which is either a constant or a v + n for a rigid variable v.BAgda"A matrix with row descriptions in b and column descriptions in c.BAgda6The Graph Monad, for constructing a graph iteratively.BAgdaScope for each flexible var.BAgdaNode labels to node numbers.BAgdaNode numbers to node labels.BAgdaNumber of nodes n.BAgdaThe edges (restrict to [0..n[).BAgda%A constraint is an edge in the graph.BAgdaFor  Arc v1 k v2 at least one of v1 or v2 is a MetaV+ (Flex), the other a MetaV or a Var (Rigid). If k <= 0 this means suc^(-k) v1 <= v2 otherwise v1 <= suc^k v3.BAgda3Which rigid variables a flex may be instatiated to.BAgdaNodes of the graph are either - flexible variables (with identifiers drawn from Int*), - rigid variables (also identified by Intn2 to be at most k(. Also adds nodes if not yet present.BAgda sizeRigid r n. returns the size expression corresponding to r + n5BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB5BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB Safe-Inferred"!$%&.0145789:;"BBBBBBBBBB Safe-Inferred!!$%&.145789:; BBBBBBBBBB BBBBBBBBBB Safe-Inferred"!$%&.145789:;πЀрҀӀԀՀր Safe-Inferred!!$%&.145789:;XCAgdaThe version of Agda.CAgdaThis package name. This is mainly intended for use in the test suites to filter ephemeral hash-fingerprinted package names like !Agda-2.6.2-5ceeWeguf1QFMaHLput4zw.CCCC Safe-Inferred$!$%&.145789:;CAgda?Information about current git commit, generated at compile timeCCCC Safe-Inferred!!$%&.145789:;CAgdaLibrary names are structured into the base name and a suffix of version numbers, e.g.  mylib-1.2.3". The version suffix is optional.CAgdaActual library name.CAgdaMajor version, minor version, subminor version, etc., all non-negative. Note: a priori, there is no reason why the version numbers should be Ints.CAgdaRaise collected  LibErrors as exception.׀AgdaGet the path to ~/.agda1 (system-specific). Can be overwritten by the AGDA_DIR environment variable.(This is not to be confused with the directory for the data files that Agda needs (e.g. the primitive modules).)CAgdaReturns the absolute default lib dir. This directory is used to store the Primitive.agda file.؀AgdaThe ~.agda libraries file lists the libraries Agda should know about. The content of  libraries is a list of paths to  .agda-lib files."Agda honors also version specific  libraries files, e.g. libraries-2.6.0.defaultLibraryFiles gives a list of all  libraries) files Agda should process by default.ـAgdaThe  defaultsFile contains a list of library names relevant for each Agda project.ڀAgdaThe ~.agda executables file lists the executables Agda should know about. The content of  executables# is a list of paths to executables."Agda honors also version specific  executables files, e.g. executables-2.6.0.defaultExecutablesFiles gives a list of all  executables# Agda should process by default.ۀAgda!Find project root by looking for  .agda-lib files.If there are none, look in the parent directories until one is found.CAgdaGet project rootCAgdaGet the contents of  .agda-lib! files in the given project root.CAgda:Get dependencies and include paths for given project root: Look for  .agda-lib files according to findAgdaLibFiles?. If none are found, use default dependencies (according to defaults/ file) and current directory (project root).܀Agda/Return list of libraries to be used by default. None if the defaults file does not exist.݀AgdaReturns the path of the  libraries1 file which lists the libraries Agda knows about.Note: file may not exist.CAgda9Parse the descriptions of the libraries Agda knows about.Returns none if there is no  libraries file.ހAgdaParse the given library files.߀Agda.Remove trailing white space and line comments.AgdaReturns the path of the  executables; file which lists the trusted executables Agda knows about.Note: file may not exist.CAgda0Return the trusted executables Agda knows about.Returns none if there is no  executables file.Agda Parse the  executables file.CAgda6Get all include pathes for a list of libraries to use.AgdafindLib x libs retrieves the matches for x from list libs. Case x is unversioned: If x is contained in libs, then that match is returned. Otherwise, the matches with the highest version number are returned.Case x is versioned: the matches with the highest version number are returned.Examples, see C.CAgdaGeneralized version of  for testing. findLib' id "a" [ "a-1", "a-02", "a-2", "b" ] == [ "a-02", "a-2" ] findLib' id "a" [ "a", "a-1", "a-01", "a-2", "b" ] == [ "a" ] findLib' id "a-1" [ "a", "a-1", "a-01", "a-2", "b" ] == [ "a-1", "a-01" ] findLib' id "a-2" [ "a", "a-1", "a-01", "a-2", "b" ] == [ "a-2" ] findLib' id "c" [ "a", "a-1", "a-01", "a-2", "b" ] == []Agdax  y if x and y have the same vvBase and either x5 has no version qualifier or the versions also match.CAgdaSplit a library name into basename and a list of version numbers. versionView "foo-1.2.3" == VersionView "foo" [1, 2, 3] versionView "foo-01.002.3" == VersionView "foo" [1, 2, 3]$Note that because of leading zeros,  versionView is not injective. (unVersionView . versionView would produce a normal form.)CAgdaPrint a  VersionView , inverse of  versionView (modulo leading zeros).ۀAgda2Candidate (init: the directory Agda was called in)AgdaActual root and  .agda-lib files for this projectAgda2Candidate (init: the directory Agda was called in)AgdaActual root and  .agda-lib files for this projectCAgda Project root.AgdaUse defaults if no  .agda-lib file exists for this project?Agda The returned LibNames are all non-empty strings.݀AgdaOverride the default  libraries file?CAgdaOverride the default  libraries file?Agda-Content of library files. (Might have empty LibNames.)ހAgdaName of  libraries file for error reporting.Agda/Library files paired with their line number in  libraries.Agda-Content of library files. (Might have empty LibNames.)CAgda Content of  executables files.CAgda libraries file (error reporting only).AgdaLibraries Agda knows about.Agda>(Non-empty) library names to be resolved to (lists of) pathes.Agda2Resolved pathes (no duplicates). Contains "." if  [LibName] does.&!""""""""""""""""""""""CCCCCCCCCCCCCCC&CCCCCCC"""""""""!C"""""""""""""CCCCCCC Safe-Inferred#!$%&.0145789:;"9.CAgdaf :: Flag opts is an action on the option record that results from parsing an option. f opts produces either an error message or an updated options recordCAgdaThe options from an OPTIONS pragma.In the future it might be nice to switch to a more structured representation. Note that, currently, there is not a one-to-one correspondence between list elements and options.CAgda%Options which can be set in a pragma.CAgdaCut off structural order comparison at some depth in termination checker?CAgda+irrelevant levels, irrelevant data matchingCAgda(Allow definitions by copattern matching?CAgda0Is pattern matching allowed in the current file?CAgda2Perform the forcing analysis on data constructors?CAgda6Perform the projection-likeness analysis on functions?CAgda$Can rewrite rules be added and used?CAgdaShould we speculatively unify function applications as if they were injective?CAgda$Should system generated projections  ProjSystem0 be printed postfix (True) or prefix (False).CAgdaShould case splitting replace variables with dot patterns (False) or keep them as variables (True).CAgda?Should instance search consider instances with qualified names?CAgda:Should conversion checker use syntactic equality shortcut?CAgdaCount extended grapheme clusters rather than code points when generating LaTeX.CAgdaAutomatic compile-time inlining for simple definitions (unless marked NOINLINE).CAgda+Use the Agda abstract machine (fastReduce)?CAgda(Use call-by-name instead of call-by-needCAgda"Check confluence of rewrite rules?CAgda)Can we split on a (@flat x : A) argument?CAgdaShould every top-level module start with an implicit statement ,open import Agda.Primitive using (Set; Prop)?CAgdaShow identity substitutions when pretty-printing terms (i.e. always show all arguments of a metavariable)CAgda'The list should not contain duplicates.CAgda-Use this (if Just) instead of .agda/librariesCAgdaUse ~.agdadefaultsCAgdalook for .agda-lib filesCAgda2Map names of trusted executables to absolute pathsCAgdaAgda REPL (-I).CAgda2In the absence of a path the project root is used.CAgdaShould the top-level module only be scope-checked, and not type-checked?CAgdaMap a function over the long options. Also removes the short options. Will be used to add the plugin name to the plugin options.CAgda-Checks that the given options are consistent.CAgda x, (i=1) -> y]dAgdaA telescope split in two.dAgda;The permutation takes us from the original telescope to firstPart ++ secondPart.dAgda(Flatten telescope: ( : Tel) -> [Type ]dAgdaOrder a flattened telescope in the correct dependeny order:  -> Permutation ( -> ~)Since reorderTel tel( uses free variable analysis of type in tel, the telescope should be cd.dAgdaUnflatten: turns a flattened telescope into a proper telescope. Must be properly ordered.dAgdaRename the variables in the telescope to the given names Precondition: size xs == size tel.dAgda(Get the suggested names from a telescopedAgda A variant of d which takes the argument names (and the argument info) from the first telescope and the variable names from the second telescope.6Precondition: the two telescopes have the same length.dAgda.Split the telescope at the specified position.dAgdaPermute telescope: permutes or drops the types in the telescope according to the given permutation. Assumes that the permutation preserves the dependencies in the telescope.3For example (Andreas, 2016-12-18, issue #2344):  tel = (A : Set) (X : _18 A) (i : Fin (_m_23 A X)) tel (de Bruijn) = 2:Set, 1:_18 0, 0:Fin(_m_23 1 /0) flattenTel tel = 2:Set, 1:_18 0, 0:Fin(_m_23 1 0) |- [ Set, _18 2, Fin (_m_23 2 1) ] perm = 0,1,2 -> 0,1 (picks the first two) renaming _ perm = [var 0, var 1, error] -- THE WRONG RENAMING! renaming _ (flipP perm) = [error, var 1, var 0] -- The correct renaming! apply to flattened tel = ... |- [ Set, _18 1, Fin (_m_23 1 60) ] permute perm it = ... |- [ Set, _18 11 ] unflatten (de Bruijn) = 1:Set, 0: _18 90 unflatten = (A : Set) (X : _18 A) dAgdaRecursively computes dependencies of a set of variables in a given telescope. Any dependencies outside of the telescope are ignored.dAgdaComputes the set of variables in a telescope whose type depend on one of the variables in the given set (including recursive dependencies). Any dependencies outside of the telescope are ignored.dAgdaSplit a telescope into the part that defines the given variables and the part that doesn't.See .dAgdaAs splitTelescope, but fails if any additional variables or reordering would be needed to make the first part well-typed.dAgdaTry to instantiate one variable in the telescope (given by its de Bruijn level) with the given value, returning the new telescope and a substitution to the old one. Returns Nothing if the given value depends (directly or indirectly) on the variable.dAgdaTry to eta-expand one variable in the telescope (given by its de Bruijn level)dAgdatelViewUpTo n t takes off the first n function types of t. Takes off all if n < 0.dAgdatelViewUpTo' n p t takes off $t$ the first n (or arbitrary many if n < 0-) function domains as long as they satify p.dAgdatelViewUpToPath n t takes off $t$ the first n (or arbitrary many if n < 0!) function domains or Path types.dAgdaLike telViewUpToPath but also returns the Boundary expected by the Path types encountered. The boundary terms live in the telescope given by the TelView. Each point of the boundary has the type of the codomain of the Path type it got taken from, see  fullBoundary.dAgda8(TelV  b, [(i,t_i,u_i)]) <- telViewUpToPathBoundary n a Input:  E a Output:  E b  E i : I  E [ (i=0) -> t_i; (i=1) -> u_i ] : bdAgda9(TelV  b, [(i,t_i,u_i)]) <- telViewUpToPathBoundaryP n a Input:  E a Output: . E b . E T is the codomain of the PathP at variable i . E i : I . E [ (i=0) -> t_i; (i=1) -> u_i ] : T Useful to reconstruct IApplyP patterns after teleNamedArgs .eAgdateleElimsB args bs = es Input: . E args :  . E T is the codomain of the PathP at variable i . E i : I . E bs = [ (i=0) -> t_i; (i=1) -> u_i ] : T Output: . | PiPath  bs A E es : AeAgda'returns Left (a,b) in case the type is Pi a b or  PathP b _ _ assumes the type is in whnf.eAgdaDecomposing a function type.eAgdaIf the given type is a Pi, pass its parts to the first continuation. If not (or blocked), pass the reduced type to the second continuation.eAgdaIf the given type is a Pi, pass its parts to the first continuation. If not (or blocked), pass the reduced type to the second continuation.eAgda&If the given type is blocked or not a Pi;, pass it reduced to the first continuation. If it is a Pi,, pass its parts to the second continuation.eAgda&If the given type is blocked or not a Pi;, pass it reduced to the first continuation. If it is a Pi,, pass its parts to the second continuation.eAgdaCompute type arityeAgdaStrips all hidden and instance Pi's and return the argument telescope and head definition name, if possible.eAgda:Register the definition with the given type as an instanceeAgdaTry to solve the instance definitions whose type is not yet known, report an error if it doesn't work and return the instance table otherwise.dAgdaA set of de Bruijn indices.AgdaOriginal telescope.Agda firstPart mentions the given variables,  secondPart not.dAgdaA list of de Bruijn indicesAgdaThe telescope to splitAgda firstPart5 mentions the given variables in the given order,  secondPart contains all other variablesdAgdaE Agda! E var k : A de Bruijn _level_Agda  E u : A[[[[ddddddddddddddddddddddddddddddddddddddddeeeeeeeeeeeeeeeeeeeeeedddddddddddddddddddddddd[ddddddddddeeeeeeeeeeeeeeeee[[[eddddddeeee Safe-Inferred!!$%&.145789:;F TAgda8Assorted warnings and errors to be displayed to the userTAgdaClassifying warnings: some are benign, others are (non-fatal) errorsTAgda(warnings that will be turned into errorsTAgdaall warnings, including errors and benign ones Note: order of constructors is important for the derived Ord instanceTAgda2Store a warning and generate highlighting from it.TAgda Raise every WARNING_ON_USAGE connected to a name.Agda;Should we only emit a single warning with this constructor.TAgda;The only way to construct a empty WarningsAndNonFatalErrorsTAgdarunning the Parse monadTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTT Safe-Inferred!!$%&.145789:;J/mAgda/Report a number of names that are not in scope.mAgda.Suggest some corrections to a misspelled name.mAgdaIf there are several warnings, remove the unsolved-constraints warning in case there are no interesting constraints to list.mAgda$Turns warnings, if any, into errors.mAgdaDepending which flags are set, one may happily ignore some warnings.mAgda8Collect all warnings that have accumulated in the state.mAgda Print range?Agda Correction suggestion generator.AgdaNames that are not in scope.mAgdaNames in scope.Agda,Canonization function for similarity search.AgdaA name which is not in scope.Agda"did you mean" hint.SmmmmmmmmmmmmmmmSmmmmmmmmmmmmmmm Safe-Inferred!!$%&.145789:;Jiiooii Safe-Inferred#!$%&.145789:;ZYAgdaPerforms void (noAbs) abstraction over telescope.YAgdaApply Elims while using the given function to report ill-typed redexes. Recursive calls for applyE and  applySubst happen at type t/ to propagate the same strategy to subtrees.YAgdaIf $v$ is a record value, canProject f v returns its field f.YAgdaEliminate a constructed term.YAgdadefApp f us vs applies Def f us to further arguments vs/, eliminating top projection redexes. If us is not empty, we cannot have a projection redex, since the record argument is the first one.YAgda  (x:A)->B(x) Y [u] = B(u)Precondition: The type must contain the right number of pis without having to perform any reduction.piApply$ is potentially unsafe, the monadic piApplyM is preferable.YAgdaIf permute  : [a] -> [a], then ,applySubst (renaming _ ) : Term  -> Term YAgdaIf permute  : [a] -> [a], then +applySubst (renamingR ) : Term  -> Term YAgdaThe permutation should permute the corresponding context. (right-to-left list)YAgda  projDropParsApply proj o args = L proj o `;` argsThis function is an optimization, saving us from construction lambdas we immediately remove through application.YAgdaTakes off all exposed function domains from the given type. This means that it does not reduce to expose Pi-types.YAgdatelView'UpTo n t takes off the first n exposed function types of t#. Takes off all (exposed ones) if n < 0.YAgdaTurn a typed binding (x1 .. xn : A) into a telescope.YAgdaTurn a typed binding (x1 .. xn : A) into a telescope.YAgda )mkPi dom t = telePi (telFromList [dom]) tYAgda)Uses free variable analysis to introduce 7 bindings.YAgdaEverything will be an 7.YAgdaOnly abstract the visible components of the telescope, and all that bind variables. Everything will be an 7! Caution: quadratic time!YAgdaAbstract over a telescope in a term, producing lambdas. Dumb abstraction: Always produces 7, never 7.$The implementation is sound because 7 does not use 7.YAgdaGiven arguments vs : tel= (vector typing), extract their individual types. Returns Nothing is tel is not long enough.YAgdaIn compiled clauses, the variables in the clause body are relative to the pattern variables (including dot patterns) instead of the clause telescope.YAgdaunivSort' univInf s gets the next higher sort of s), if it is known (i.e. it is not just  UnivSort s).Precondition: s is reducedYAgdaReturns Nothing4 for unknown (meta) sorts, and otherwise returns  Just (b,f) where b indicates smallness and f fibrancy. I.e., b is True# for (relatively) small sorts like Set l and Prop l, and instead b is False for large sorts such as Set.YAgdaCompute the sort of a function type from the sorts of its domain and codomain.YAgdaCompute the sort of a pi type from the sorts of its domain and codomain.YAgdaGiven two levels a and b , compute a E b" and return its canonical form.YAgdaEquality of binders relies on weakening which is a special case of renaming which is a special case of substitution.YAgda Syntactic 7 equality, ignores stuff below DontCare and sharing.YAgda Syntactic 7$ equality, ignores sort annotations.ZAgdatel E ( E lhs C rhs : t) becomes tel,  E lhs C rhs : t) we do not need to change lhs, rhs, and t since they live in . See 'Abstract Clause'.ZAgda)Make sure we only drop variable patterns.666666669999;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;YYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYYY66666666 Safe-Inferred!!$%&.145789:;b RAgdaGets the include directories.Precondition: C must be nonempty (i.e. X must have run).XAgdaSets the pragma options.XAgdaSets the command line options (both persistent and pragma options are updated).Relative include directories are made absolute with respect to the current working directory. If the include directories have changed (thus, they are  now, and were previously  something>), then the state is reset (completely, see setIncludeDirs) ./An empty list of relative include directories ( []) is interpreted as ["."].YAgdaDisable display forms.YAgdaDisable display forms.YAgda#Check if display forms are enabled.YAgdaMakes the given directories absolute and stores them as include directories.If the include directories change, then the state is reset (completely, except for the include directories and some other things). An empty list is interpreted as ["."].YAgdaSwitch on printing of implicit and irrelevant arguments. E.g. for reification in with-function generation. Restores all C> after completion. Thus, do not attempt to make persistent C changes in a Y bracket.YAgdaChange C* for a computation and restore afterwards.YAgda Returns the  currently in effect.XAgda%The base directory of relative paths.XAgda%The base directory of relative paths.YAgda%The base directory of relative paths.YAgdaNew include directories.Agda%The base directory of relative paths.RRXXXXXXYYYYYYYYYYYYYYYYYYYYYYYXXXRXXXYYYYYYYRYYYYYYYYYYYYYYYY Safe-Inferred!!$%&.145789:;n"VAgda:Resets the non-persistent part of the type checking state.VAgda&Resets all of the type checking state. Keep only * and backend information.VAgdaRestore ! after performing subcomputation.In contrast to , the ** info from the subcomputation is saved.VAgdaSame as V but also returns the state in which we were just before reverting it.VAgdaSame as V but keep all warnings.VAgda:Allow rolling back the state changes of a TCM computation.VAgdaA fresh TCM instance.The computation is run in a fresh state, with the exception that the persistent state is preserved. If the computation changes the state, then these changes are ignored, except for changes to the persistent state. (Changes to the persistent state are also ignored if errors other than type errors or IO exceptions are encountered.)VAgda Lens for J.VAgdaGet the current scope.VAgdaSet the current scope.VAgda;Modify the current scope without updating the inverse maps.VAgdaModify the current scope.VAgda Get a part of the current scope.VAgda&Run a computation in a modified scope.VAgda#Run a computation in a local scope.VAgdaSame as V-, but discard the scope from the computation.VAgda2Discard any changes to the scope by a computation.VAgda Scope error.VAgdaDebug print the scope.VAgdaUpdate a possibly imported definition. Warning: changes made to imported definitions (during type checking) will not persist outside the current module. This function is currently used to update the compiled representation of a function during compilation.VAgdaRun some computation in a different signature, restore original signature.VAgdaSet the top-level module. This affects the global module id of freshly generated names.VAgdaUse a different top-level module for a computation. Used when generating names for imported modules.VAgda Lens for K.VAgda,Get both local and imported pattern synonymsVAgdaLens getter for * from .VAgda Lens map for *.VAgdaLens getter for * from .VAgdaLens modify for *.VAgda>Look through the signature and reconstruct the instance table.VAgda Lens for K.VAgda4Remove all instances whose type is still unresolved.VAgda/Add an instance whose type is still unresolved.VAgdaAdd instance to some `class'.VAgdaName of the instance.AgdaName of the class.VVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVV Safe-Inferred!!$%&.145789:;vRAgda?Debug print some lines if the verbosity level for the given C is at least C.Note: In the presence of OverloadedStrings , just @( traceS key level "Literate string"  gives an Ambiguous type variable error in  GHC@. Use the legacy functions S and S instead then.SAgda?Debug print some lines if the verbosity level for the given C is at least C.Note: In the presence of OverloadedStrings , just @) reportS key level "Literate string"  gives an Ambiguous type variable error in  GHC@. Use the legacy functions S and S instead then.SAgda=Print brackets around debug messages issued by a computation.SAgda.Check whether we are currently debug printing.SAgda;Flag in a computation that we are currently debug printing.SAgda%Print a debug message if switched on.SAgda/During printing, catch internal errors of kind  and print them.SAgda#Conditionally println debug string.SAgdaConditionally render debug s and print it.SAgda(Debug print the result of a computation.SAgdaConditionally render debug s, print it, and then continue.SAgda5Check whether a certain verbosity level is activated.-Precondition: The level must be non-negative.SAgdaCheck whether a certain verbosity level is activated (exact match).SAgdaRun a computation if a certain verbosity level is activated (exact match).SAgdaExpected a type to be an application of a particular datatype.DAgdaconstructor, datatypeDAgdaDatatype, constructors.DAgdaconstructor, typeDAgdaThe left hand side of a function definition has a hidden argument where a non-hidden was expected.DAgda9Expected a non-hidden function and found a hidden lambda.DAgdaA function is applied to a hidden argument where a non-hidden was expected.DAgdaA function is applied to a hidden named argument it does not have. The list contains names of possible hidden arguments at this point.DAgda0Wrong user-given relevance annotation in lambda.DAgda/Wrong user-given quantity annotation in lambda.DAgda/Wrong user-given cohesion annotation in lambda.DAgdaThe given quantity does not correspond to the expected quantity.DAgdaFailed to apply injectivity to constructor of indexed datatypeEAgda=Can't solve equation because variable occurs in (type of) lhsEAgda=Can't solve reflexive equation because --without-K is enabledEAgda?Can't solve equation because solution modality is less "usable"EAgdaError when splitting a pattern variable into possible constructor patterns.EAgdaNeither data type nor record.EAgda'Type could not be sufficiently reduced.EAgda8Data type, but in erased position. If the boolean is ~, then the reason for the error is that the K rule is turned off.EAgdaSplit on codata not allowed. UNUSED, but keep! -- | NoRecordConstructor Type -- ^ record type, but no constructorEAgdaCopattern split with a catchallEAgda-We do not know the target type of the clause.EAgda!Target type is not a record type.EAgdaBlocking metavariable (if any)EAgda Constructor.EAgdaContext for indices.EAgda,Inferred indices (from type of constructor).EAgda)Expected indices (from checking pattern).EAgda$Reason(s) why unification got stuck.EAgdaInformation about a mutual block which did not pass the termination checker.EAgdaThe functions which failed to check. (May not include automatically generated functions.)EAgdaThe problematic call sites.EAgdaInformation about a call.EAgdaTarget function name.EAgdaRange of the target function.EAgda+To be formatted representation of the call.EAgdaLocation in the internal Agda source code location where the error raisedEAgda"Range where the warning was raisedEAgdaThe warning itselfEAgdaThe warning printed in the state and environment where it was raisedEAgda*Should the warning be affected by caching.EAgdaEach redundant field comes with a range of associated dead code.EAgdaRecord type, fields not supplied by user, non-fields but supplied. The redundant fields come with a range of associated dead code.EAgda4`UnreachableClauses f rs` means that the clauses in f' whose ranges are rs are unreachableEAgda!`CoverageIssue f pss` means that pss are not covered in fEAgdaDo not use directly with warningEAgdaDo not use directly with warningEAgdaDo not use directly with warningEAgdaIn `OldBuiltin old new`, the BUILTIN old has been replaced by newEAgdaIf the user wrote just {-# REWRITE #-}.EAgda An empty where block is dead code.EAgdaIf the user wrote something other than an unqualified name in the as clause of an import statement. The $ gives optionally extra explanation.EAgdaIf a renaming import directive introduces a name or module name clash in the exported names of a module. (See issue #4154.)EAgdaThe  'pattern'5 declaration is useless in the presence of either  coinductive or  eta-equality. Content of ! is "coinductive" or "eta", resp.FAgdaIf the user opens a module public before the module header. (See issue #2377.)FAgda Names in 5 directive that don't hide anything imported by a  directive.FAgdaAn instance was declared with an implicit argument, which means it will never actually be considered by instance search.FAgdaThe type of an instance argument doesn't end in a named or variable type, so it will never be considered by instance search.FAgdaAs InstanceWithExplicitArg, but for local bindings rather than top-level instances.FAgda&The --inversion-max-depth was reached.FAgdaA coinductive record was declared but neither --guardedness nor --sized-types is enabled.FAgda'Harmless generic warning (not an error)FAgda=Generic error which doesn't abort proceedings (not a warning)FAgda:Generic warning when code is useless and thus ignored.   is for dead code highlighting.FAgdaUnsafe OPTIONS.FAgdaETA pragma is unsafe.FAgda)`DeprecationWarning old new version`: old is deprecated, use new( instead. This will be an error in Agda version.FAgdaUser-defined warning (e.g. to mention that a name is deprecated)FAgda'Duplicate mentions of the same name in using directive(s).FAgdaFixity of modules cannot be changed via renaming (since modules have no fixity).FAgdaSome imported names are not actually exported by the source module. The second argument is the names that could be exported. The third argument is the module names that could be exported.FAgdaImporting a file using an infective option into one which doesn'tFAgdaImporting a file not using a coinfective option from one which doesFAgdaConfluence checker found critical pair and equality checking resulted in a type errorFAgdaConfluence checker got stuck on computing overlap between two rewrite rulesFAgda+The global confluence checker found a term u that reduces to both v1 and v22 and there is no rule to resolve the ambiguity.FAgda+The global confluence checker found a term u that reduces to v, but v does not reduce to rho(u).FAgda&COMPILE directive for an erased symbolFAgda&Out of scope error we can recover fromFAgda;The as-name in an as-pattern may not shadow a constructor (False) or pattern synonym name (True,), because this can be confusing to read.FAgdaRanges of checked arguments, where present. e.g. inserted implicits have no correponding abstract syntax.FAgda&Checked and inserted arguments so far.FAgdaConstraints for the head so far, i.e. before applying the correponding elim.FAgda%Type for the rest of the application.FAgdaA candidate solution for an instance meta is a term with its type. It may be the case that the candidate is not fully applied yet or of the wrong type, hence the need for the type.FAgdaAdd implicit arguments in the end until type is no longer hidden 7.FAgda!Do not append implicit arguments.FAgdaMakes  doExpandLast have no effect. Used to avoid implicit insertion of arguments to metavariables.FAgda6Abstract things in the current module can be accessed.FAgda#No abstract things can be accessed.FAgda$All abstract things can be accessed.FAgdaThe Context is a stack of Fs.FAgda=The path to the file that is currently being type-checked. ~9 if we do not have a file (like in interactive mode see  CommandLine).FAgda4anonymous modules and their number of free variablesFAgdaThe module stack with the entry being the top-level module as Agda chases modules. It will be empty if there is no main module, will have a single entry for the top level module, or more when descending past the main module. This is used to detect import cycles and in some cases highlighting behavior. The level of a given module is not necessarily the same as the length, in the module dependency graph, of the shortest path from the top-level module; it depends on in which order Agda chooses to chase dependencies.FAgda!the current (if any) mutual blockFAgda/are we inside the scope of a termination pragmaFAgda,are we inside the scope of a coverage pragmaFAgdaare we inside a make-case (if so, ignore forcing analysis in unifier)FAgda>Are we currently in the process of solving active constraints?FAgdaHave we stepped into the where-declarations of a clause? Everything under a where# will be checked with this flag on.FAgda&Are we working on types? Turned on by  workOnTypes.FAgdaAre we allowed to assign metas?FAgdaWhen checking the typesignature of a public definition or the body of a non-abstract definition this is true. To prevent information about abstract things leaking outside the module.FAgda7 component: Are we checking an irrelevant argument? (= Irrelevant) Then top-level irrelevant declarations are enabled. Other value: Relevant*, then only relevant decls. are available.; component: Are we checking a runtime-irrelevant thing? (=<) Then runtime-irrelevant things are usable. Other value:  Quantity1, runtime relevant.  Quantity/ is not allowed here, see Bob Atkey, LiCS 2018.FAgdaAre we currently case-splitting on a strict datatype (i.e. in SSet)? If yes, the pattern-matching unifier will solve reflexive equations even --without-K.FAgda+Sometimes we want to disable display forms.FAgda8Interactive highlighting uses this range rather than F.FAgdaWhat is the current clause we are type-checking? Will be recorded in interaction points in this clause.FAgdawhat we're doing at the momentFAgdaSet to F+ when imported modules are type-checked.FAgdaWhen type-checking an alias f=e, we do not want to insert hidden arguments in the end, because these will become unsolved metas.FAgdaWe are reducing an application of this function. (For debugging of incomplete matches only.)FAgdaDid we encounter a simplification (proper match) during the current reduction process?FAgdaInjectivity can cause non-termination for unsolvable contraints (#431, #3067). Keep a limit on the nesting depth of injectivity uses.FAgdaWhen True, the conversion checker will consider all term constructors as injective, including blocked function applications and metas. Warning: this should only be used when not assigning any metas (e.g. when envAssignMetas is False or when running pureEqualTerms.) or else we get non-unique meta solutions.FAgdaWhen True, types will be omitted from printed pi types if they can be inferred.FAgdaWhen True, throw away meta numbers and meta elims. This is used for reifying terms for feeding into the user's source code, e.g., for the interaction tactics solveAll.FAgdaUsed by the scope checker to make sure that certain forms of expressions are not used inside dot patterns: extended lambdas and let-expressions.FAgdaUntil we get a termination checker for instance search (#1743) we limit the search depth to ensure termination.FAgda#3004: pattern lambdas with copatterns may refer to themselves. We don't have a good story for what to do in this case, but at least printing shouldn't loop. Here we keep track of which pattern lambdas we are currently in the process of printing.FAgda+Use call-by-need evaluation for reductions.FAgdaCheckpoints track the evolution of the context as we go under binders or refine it by pattern matching.FAgdaKeeps the substitution from each previous checkpoint to the current context.FAgda"Should new metas generalized over.FAgda(Values for used generalizable variables.FAgdaIs some backend active at the moment, and if yes, which? NB: we only store the  here, otherwise instance Data TCEnv is not derivable. The actual backend can be obtained from the name via K.FAgdaAre we currently computing the overlap between two rewrite rules for the purpose of confluence checking?FAgdaAre we currently in the process of executing an elaborate-and-give interactive command?FAgda Via stdout.FAgdaBoth via files and via stdout.FAgdaThis includes both non-interactive highlighting and interactive highlighting of the expression that is currently being type-checked.GAgda-Builtin of any kind. Type can be checked (Just t) or inferred (Nothing). The second argument is the hook for the verification function.GAgda2When typechecking something of the following form:"instance x : _ x = y it's not yet known where to add x, so we add it to a list of unresolved instances and we'll deal with it later.GAgdaThe instance table is a Map' associating to every name of record data typepostulate its list of instancesGAgda8Highlight (interactively) if and only if the boolean is ~.GAgda*Interaction command: show module contents.GAgdaused by setCurrentRangeGAgda PrimitivesGAgda Controlling reduce.GAgda:(Projection and) projection-like functions may be reduced.GAgda'Functions marked INLINE may be reduced.GAgda%Copattern definitions may be reduced.GAgda6Non-recursive functions and primitives may be reduced.GAgda(Even recursive functions may be reduced.GAgdaReduce 7 terms.GAgdaAllow  allReductions in types, even if not allowed at term level (used by confluence checker)GAgda9Functions whose termination has not (yet) been confirmed.GAgda0Functions that have failed termination checking.GAgdaThree cases: 1. not reduced, 2. reduced, but blocked, 3. reduced, not blocked.GAgdaDid we encounter a simplifying reduction? In terms of CIC, that would be a iota-reduction. In terms of Agda, this is a constructor or literal pattern that matched. Just beta-reduction (substitution) or delta-reduction (unfolding of definitions) does not count as simplifying?GAgda PostulateGAgdaData or record type signature that doesn't yet have a definitionGAgda&Generalizable variable (introduced in  generalize block)GAgda Returned by  getConstInfo if definition is abstract.GAgdaPrimitive or builtin functions.GAgda5Can transp for this postulate be constant? Set to True for bultins like String.GAgda~* while function is still type-checked. Just cc after type and coverage checking and translation to case trees.GAgdaThe split tree constructed by the coverage checker. Needed to re-compile the clauses after forcing translation.GAgda2Intermediate representation for compiler backends.GAgdaCovering clauses computed by coverage checking. Erased by (IApply) confluence checking(?)GAgdaMutually recursive functions, datas and records. Does include this function. Empty list if not recursive. Nothing- if not yet computed (by positivity checker).GAgda+Are the clauses of this definition delayed?GAgdaIs it a record projection? If yes, then return the name of the record type and index of the record argument. Start counting with 1, because 0 means that it is already applied to the record. (Can happen in module instantiation.) This information is used in the termination checker.HAgda9Has this function been termination checked? Did it pass?HAgdaIs this function generated from an extended lambda? If yes, then return the number of hidden and non-hidden lambda-lifted argumentsHAgdaIs this a generated with-function? If yes, then what's the name of the parent function.HAgdaNumber of parameters.HAgdaNumber of indices.HAgda(This might be in an instantiated module.HAgdaConstructor names , ordered according to the order of their definition.HAgdaMutually recursive functions, datas and records. Does include this data type. Empty if not recursive. Nothing- if not yet computed (by positivity checker).HAgda+Path constructor names (subset of dataCons)HAgdaNumber of parameters.HAgdaWas this record type created by a module application? If yes, the clause is its definition (linking back to the original record type).HAgdaConstructor name and fields.HAgdaDoes this record have a  constructor?HAgdaThe record field names.HAgdaThe record field telescope. (Includes record parameters.) Note: $TelV recTel _ == telView' recConType . Thus, recTel is redundant.HAgdaMutually recursive functions, datas and record>s. Does include this record. Empty if not recursive. Nothing- if not yet computed (by positivity checker).HAgda#Eta-expand at this record type? False for unguarded recursive records and coinductive records unless the user specifies otherwise.HAgdaIn case eta-equality is off, do we allow pattern matching on the constructor or construction by copattern matching? Having both loses subject reduction, see issue #4560. After positivity checking, this field is obsolete, part of H.HAgda or *? Matters only for recursive records. ~ means that the user did not specify it, which is an error for recursive records.HAgdaNumber of parameters.HAgda+Number of arguments (excluding parameters).HAgdaName of (original) constructor and fields. (This might be in a module instance.)HAgda Name of datatype or record type.HAgdaInductive or coinductive?HAgdaCubical composition.HAgda Projections. ~ if not yet computed.HAgdaWhich arguments are forced (i.e. determined by the type of the constructor)? Either this list is empty (if the forcing analysis isn't run), or its length is conArity.HAgdaWhich arguments are erased at runtime (computed during compilation to treeless)? ~ means erased,  means retained. ~ if no erasure analysis has been performed yet. The length of the list is conArity.HAgda for primitive functions, not null for builtin functions.HAgdaBuiltin functions can have inverses. For instance, natural number addition.HAgda~ for primitive functions, ~ something for builtin functions.HAgda r .p2 (Invariant: the number of abstractions equals H.) In case of a projection-like function, just the function symbol is returned as 7: t = pars -> f.HAgda,Additional information for extended lambdas.HAgdaFor complicated reasons the scope checker decides the QName of a pattern lambda, and thus its module. We really need to decide the module during type checking though, since if the lambda appears in a refined context the module picked by the scope checker has very much the wrong parameters.HAgda2Was this definition created from an absurd lambda  ()?HAgdaAn alternative representation of partial elements in a telescope:  E  . [A uA, ... , A uA] :  C PartialP (D_: :) T see cubicaltt paper (however we do not store the type T).HAgda4the telescope , binding vars for the clauses,  E HAgda?a system [A uA, ... , A uA] where ,  E : and , , : E u:HAgda;The backends are responsible for parsing their own pragmas.HAgdaInformation about whether an argument is forced by the type of a function.HAgdamonotoneHAgdaantitoneHAgdano information (mixed variance)HAgdaconstantHAgda5When lambda-lifting new args are generalizable if H, also when the number is zero.HAgdaHiding should not be used.HAgda-The canonical name, used e.g. in compilation.HAgdaType of the lifted definition.HAgdaVariance information on arguments of the definition. Does not include info for dropped parameters to projection(-like) functions and constructors.HAgdaPositivity information on arguments of the definition. Does not include info for dropped parameters to projection(-like) functions and constructors.HAgda)How many arguments should be generalised.HAgdaGives the name of the (bound variable) parameter for named generalized parameters. This is needed to bring it into scope when type checking the data/record definition corresponding to a type with generalized parameters.HAgdaJust q/ when this definition is an instance of class qHAgda:Has this function been created by a module instantiation?HAgdaThe set of symbols with rewrite rules that match against this symbolHAgda8should compilers skip this? Used for e.g. cubical's compHAgdaShould the def be treated as injective by the pattern matching unifier?HAgda)Is this a function defined by copatterns?HAgdaWhat blocking tag to use when we cannot reduce this def? Used when checking a function definition is blocked on a meta in the type.HAgda%The language used for the definition.HAgda?Rewrite rules can be added independently from function clauses.HAgdaName of rewrite rule q :  C f ps D rhs where D is the rewrite relation.HAgda.HAgdaf.HAgda  E f ps : t.HAgda  E rhs : t.HAgda E t.HAgdaWas this rewrite rule created from a clause in the definition of the function?HAgda1Non-linear (non-constructor) first-order pattern.HAgdaMatches anything (modulo non-linearity) that only contains bound variables that occur in the given arguments.IAgdaMatches f esIAgdaMatches  x C tIAgdaMatches  (x : A) C BIAgda"Matches a sort of the given shape.IAgdaMatches x es# where x is a lambda-bound variableIAgda'Matches the term modulo  (ideally ).IAgdaA structured presentation of a 7 for reification into .IAgda(f vs | ws) es. The first I is the parent function f with its args vs. The list of Is are the with expressions ws . The 7 are additional arguments es (possible in case the with-application is of function type) or projections (if it is of record type).IAgdac vs.IAgdad vs.IAgda.v.IAgdav.IAgdaA  DisplayForm is in essence a rewrite rule  q ts --> dt: for a defined symbol (could be a constructor as well) q. The right hand side is a I which is used to reify to a more readable . The patterns ts are just terms, but the first  dfPatternVars: variables are pattern variables that matches any term.IAgdaNumber n of pattern variables in I.IAgdaLeft hand side patterns, the n first free variables are pattern variables, any variables above n are fixed and only match that particular variable. This happens when you have display forms inside parameterised modules that match on the module parameters. The  is ignored in these patterns.IAgdaRight hand side.IAgda'The rewrite rules defined in this file.IAgda0Which clause is an interaction point located in?IAgda4The interaction point is not in the rhs of a clause.IAgdaThe name of the function.IAgda*The number of the clause of this function.IAgdaThe type of the functionIAgdaModule parameter substitutionIAgdaThe original AST clause.IAgda&Environment for rechecking the clause.IAgda The boundary imposed by the LHS.IAgdaDatatype representing a single boundary condition: x_0 = u_0, ... ,x_n = u_n E t = ?n esIAgda x_0 = u_0, ... ,x_n = u_nIAgda tIAgda ?n esIAgdaIs ?n overapplied in ?n es ?IAgdaFlag to indicate whether the meta is overapplied in the constraint. A meta is overapplied if it has more arguments than the size of the telescope in its creation environment (as stored in MetaInfo).IAgda/Data structure managing the interaction points.We never remove interaction points from this map, only set their I to True. (Issue #2368)IAgdaInteraction points are created by the scope checker who sets the range. The meta variable is created by the type checker and then hooked up to the interaction point.IAgda&The position of the interaction point.IAgda0The meta variable, if any, holding the type etc.IAgda/Has this interaction point already been solved?IAgdaThe clause of the interaction point (if any). Used for case splitting.IAgdaName suggestion for meta variable. Empty string means no suggestion.IAgdaMetaInfo4 is cloned from one meta to the next during pruning.IAgda-Instantiable with irrelevant/erased solution?IAgda7Run the extended occurs check that goes in definitions?IAgdaUsed for printing. Just x8 if meta-variable comes from omitted argument with name x.IAgdaShould this meta be generalized if unsolved? If so, at what ArgInfo?IAgdaMeta variable priority: When we have an equation between meta-variables, which one should be instantiated?6Higher value means higher priority to be instantiated.IAgda( (xs : tA) C e) : t This is not an instance of I as the domain type has already been checked. For example, when checking '( (x y : Fin _) C e) : (x : Fin n) C ? we want to postpone ( (y : Fin n) C e) : ? where Fin n is a 7 rather than an >.IAgda,Quote the given term and check type against 7IAgdametas created for hidden and instance arguments in the principal argument's typeIAgdaprincipal argument's type, stripped of hidden and instance argumentsIAgda Solving a I constraint may or may not check the target type. If it did, it returns a handle to any unsolved constraints.IAgda4solved by term (abstracted over some free variables)IAgdaunsolvedIAgda+open, to be instantiated by instance searchIAgda(solution blocked by unsolved constraintsIAgdaFrozen meta variable cannot be instantiated by unification. This serves to prevent the completion of a definition by its use outside of the current block. (See issues 118, 288, 399).IAgdaDo not instantiate.IAgda4some metavariables are more eager to be instantiatedIAgdaa metavariable doesn't have to depend on all variables in the context, this "permutation" will throw away the ones it does not depend onIAgdameta variables scheduled for eta-expansion but blocked by this oneIAgdaare we past the point where we can instantiate this meta variable?IAgdaJust m3 means that this meta-variable will be equated to m$ when the latter is unblocked. See .IAgdaThe value of a generalizable variable. This is created to be a generalizable meta before checking the type to be generalized.IAgda2Generalize because it is a generalizable variable.IAgdaGeneralize because it is a metavariable and we're currently checking the type of a generalizable variable (this should get the default modality).IAgdaDon't generalize.IAgdaParametrized since it is used without MetaId when creating a new meta.IAgdaare we checking (CmpLeq) or inferring (CmpEq ) the type?IAgdaA thing tagged with the context it came from. Also keeps the substitution from previous checkpoints. This lets us handle the case when an open thing was created in a context that we have since exited. Remember which module it's from to make sure we don't get confused by checkpoints from other files.JAgdaWe can either compare two terms at a given type, or compare two types without knowing (or caring about) their sorts.JAgdaType should not be Size5. But currently, we do not rely on this invariant.JAgda Replaces AsTermsOf Size.JAgdaAn extension of  to >=.JAgdaMeta created for a term blocked by a postponed type checking problem or unsolved constraints. The I( for the meta (when unsolved) is either I or I.JAgda+The range is the one of the absurd pattern.JAgdaCheck that the 7. is either not a SIZELT or a non-empty SIZELT.JAgdathe first argument is the instance argument and the second one is the list of candidates (or Nothing if we haven@t determined the list of candidates yet)JAgda2Last argument is the error causing us to postpone.JAgdaFirst argument is computation and the others are hole and goal typeJAgdaCheckLockedVars t ty lk lk_ty with t : ty,  lk : lk_ty and t lk well-typed.JAgda)is the term usable at the given modality?JAgdaHash of the source code.JAgdaThe source code. The source code is stored so that the HTML and LaTeX backends can generate their output without having to re-read the (possibly out of date) source code.JAgda4Source file type, determined from the file extensionJAgda"Imported modules and their hashes.JAgdaModule name of this interface.JAgdaScope defined by this module.Andreas, AIM XX: Too avoid duplicate serialization, this field is not serialized, so if you deserialize an interface, iScope will be empty. But constructIScope constructs J from J.JAgda1Scope after we loaded this interface. Used in  and .JAgda-Display forms added for imported identifiers.JAgda&User warnings for imported identifiersJAgda8Whether this module should raise a warning when importedJAgda$Pragma options set in library files.JAgdaPragma options set in the file.JAgdaOptions/features used when checking the file (can be different from options set directly in the file).JAgdaWarnings were encountered when the module was type checked. These might include warnings not stored in the interface itself, specifically unsolved interaction metas. See Agda.Interaction.ImportsJAgda~ if the module is a primitive module, which should always be importable.JAgdaThe J used to create the JJAgdaDistinguishes between type-checked and scope-checked interfaces when stored in the map of J.JAgdaA monad that has read and write access to the stConcreteNames part of the TCState. Basically, this is a synonym for `MonadState ConcreteNames m` (which cannot be used directly because of the limitations of Haskell's typeclass system).JAgdaMaps source file names to the corresponding top-level module names.JAgdaCreate a fresh name from a.JAgda0A complete log for a module will look like this:JJ, entering the main module.JJJ*, for declarations and nested modulesJ, leaving the main module.JAgdaNever a Section or ScopeDeclJAgdaLike J, but storing the log for an ongoing type checking of a module. Stored in reverse order (last performed action first).JAgdaA log of what the type checker does and states after the action is completed. The cached version is stored first executed action first.JAgdaA part of the state which is not reverted when an error is thrown or the state is reset.JAgdaCallback function to call when there is a response to give to the interactive frontend. See the documentation of 3.JAgdaStructure to track how much CPU time was spent on which Agda phase. Needs to be a strict field to avoid space leaks!JAgdaShould be strict field.JAgdaCached typechecking state from the last loaded file. Should be Nothing when checking imports.JAgda#Current backends with their optionsJAgda)A mutual block of names in the signature.JAgda&The original info of the mutual block.JAgdaHighlighting info.JAgdaDisambiguation carried out by the type checker. Maps position of first name character to disambiguated  for each $ already passed by the type checker.JAgdaDirty when a constraint is added, used to prevent pointer update. Currently unused.JAgdaDefinitions to be considered during occurs check. Initialized to the current mutual block before the check. During occurs check, we remove definitions from this set as soon we have checked them.JAgdaDeclared identifiers of the current file. These will be serialized after successful type checking.KAgdaFor each module remember the checkpoint corresponding to the orignal context of the module parameters.KAgda-Display forms we add for imported identifiersKAgdaThe current module is available after it has been type checked.KAgdaMap keeping track of concrete names assigned to each abstract name (can be more than one name in case the first one is shadowed)KAgdaMap keeping track for each name root (= name w/o numeric suffixes) what names with the same root have been used during a TC computation. This information is used to build the ShadowingNames map.KAgdaMap keeping track for each (abstract) name the list of all (raw) names that it could maybe be shadowed by.KAgdaCounters to collect various statistics about meta variables etc. Only for current file.KAgdaShould we instantiate away blocking metas? This can produce ill-typed terms but they are often more readable. See issue #3606. Best set to True only for calls to pretty*/reify to limit unwanted reductions.KAgda/Local partial definitions, to be stored in the  InterfaceKAgda1Name disambiguation for the sake of highlighting.KAgdaHighlighting info for tokens and Happy parser warnings (but not for those tokens/warnings for which highlighting exists in J).KAgda?Imported declared identifiers. Those most not be serialized!KAgda2Pattern synonyms of the current file. Serialized.KAgda3Imported pattern synonyms. Must not be serialized!KAgdaCollected generalizable variables; used during scope checking of termsKAgda&Options applying to the current file. OPTIONS! pragmas only affect this field.KAgda;Display forms added by someone else to imported identifiersKAgda{-# FOREIGN #-} code that should be included in the compiled output. Does not include code for imported modules.KAgda Imported  UserWarnings, not to be stored in the  InterfaceKAgdaLocally defined  UserWarnings, to be stored in the  InterfaceKAgda=Whether the current module should raise a warning when openedKAgda6Imported partial definitions, not to be stored in the  InterfaceKAgdaMap from directories to paths of closest enclosing .agda-lib files (or Nothing if there are none).KAgda:Contents of .agda-lib files that have already been parsed.KAgda/The state which is frozen after scope checking.KAgda1The state which is modified after scope checking.KAgda'State which is forever, like a diamond.KAgdaEmpty persistent state.KAgdaEmpty state of type checker.KAgda Creates a J map based on K. O(n log n).For a single reverse lookup in K, rather use lookupModuleFromSourse.KAgda Lookup an   in K.O(n).KAgdaCombines the source hash and the (full) hashes of the imported modules.KAgdaA lens for the J field of the J type.LAgdaEmbed  into J.LAgda!Flip the direction of comparison.LAgdaTurn a  function into a J function. Property:  dirToCmp f (fromCmp cmp) = f cmpLAgda$By default, we have no display form.LAgda+Create a definition with sensible defaults.LAgda>Building the projection function (which drops the parameters).LAgda,The info of the principal (record) argument.LAgda3Make sure we do not overwrite a user specification.LAgdaIs the record type recursive?LAgdaA template for creating G% definitions, with sensible defaults.LAgdaChecking whether we are dealing with a function yet to be defined.LAgdaConceptually: 2redBind m f k = either (return . Left . f) k =<< mLAgda:Not quite all reductions (skip non-terminating reductions)LAgda+Are the clauses of this definition delayed?LAgda2Has the definition failed the termination checker?LAgdaHas the definition not termination checked or did the check fail?LAgda&ifTopLevelAndHighlightingLevelIs l b m runs m when we're type-checking the top-level module (or before we've started doing this) and either the highlighting level is at least l or b is ~.LAgda$ifTopLevelAndHighlightingLevelIs l m runs m when we're type-checking the top-level module (or before we've started doing this) and the highlighting level is at least l.MAgda&Modify the lens-indicated part of the TCEnv in a subcomputation.MAgda A variant of D6 in which the computation is strict in the new state.MAgdaOverwrite the part of the  focused on by the lens.MAgdaModify the part of the  focused on by the lens.MAgda'Modify a part of the state monadically.MAgdaModify the part of the 0 focused on by the lens, and return some result.MAgda?Modify a part of the state monadically, and return some result.MAgda.Preserve the state of the failing computation.MAgdaExecute a finalizer even when an exception is thrown. Does not catch any errors. In case both the regular computation and the finalizer throw an exception, the one of the finalizer is propagated.MAgdaUtility function for 1-arg constructed type errors. Note that the  HasCallStack+ constraint is on the *resulting* function.MAgda4Running the type checking monad (most general form).MAgdaRunning the type checking monad on toplevel (with initial state).MAgdaM runs a safe  action (a 9 action which cannot fail, except that it might raise D!s) in the initial environment.MAgda6Runs the given computation in a separate thread, with a copy' of the current state and environment.Note that Agda sometimes uses actual, mutable state. If the computation given to forkTCM tries to modify this state, then bad things can happen, because accesses are not mutually exclusive. The forkTCM8 function has been added mainly to allow the thread to read7 (a snapshot of) the current state in a convenient way.Note also that exceptions which are raised in the thread are not propagated to the parent, so the thread should not do anything important.MAgda$Base name for patterns in telescopesMAgda&Base name for extended lambda patternsMAgdaA command sent when an exit command is about to be completed.3Agda The default 3 function prints certain things to stdout (other things generate internal errors).UAgda!Are implicit arguments displayed?UAgda#Are irrelevant arguments displayed?UAgda.Has the module been successfully type checked?UAgdaEntry in context.UAgdaThe original concrete name.UAgda&The name reified from abstract syntax.UAgda The type.UAgda)The value (if it is a let-bound variable)UAgda Whether the U is in scope.UAgda/Auxiliary information that comes with Goal TypeUAgda Errors that goes into Info_ErrorWhen an error message is displayed this constructor should be used, if appropriate.UAgdaGoals & WarningsUAgdaWhen an error message is displayed this constructor should be used, if appropriate.VAgdaV, denotes either an error or a success (when 3< is present) TODO: split these into separate constructorsVAgda7Yes, remove all token-based highlighting from the file.VAgdaNo.33UUUU3UUU3VV3UUUUUUUVVVVVVVVV3VV333333333333333TUUUUUUUUUUUUUUUUUUUUUUU333333333333333VV3VV3UUUUUUUVVVVVVVVVUUUUUUUTUUUUUUUUUUUUUUUU3UUUU3UUU33 Safe-Inferred!!$%&.145789:;d;8TAgda A subset of T.TAgda8Ignore additional checks, like termination/positivity...TAgdaDon't ignore any checks.TAgda/Ordered ascendingly by degree of normalization.TAgdaAvailable backends.TAgdaThe T monad. ! state holds the remaining input.TAgdaOrder the fields of a record construction. Raise generated Es as warnings.jAgda>Order the fields of a record construction. Raise generated E s as errors.jAgdaA record field assignment record{xs = es}+ might not mention all visible fields. insertMissingFields inserts placeholders for the missing visible fields and returns the values in order of the fields in the record declaration.jAgdaA record field assignment record{xs = es}+ might not mention all visible fields. insertMissingFields inserts placeholders for the missing visible fields and returns the values in order of the fields in the record declaration.jAgdaA record field assignment record{xs = es}+ might not mention all visible fields. insertMissingFields inserts placeholders for the missing visible fields and returns the values in order of the fields in the record declaration.jAgdaGet the definition for a record. Throws an exception if the name does not refer to a record or the record is abstract.jAgda.Get the record name belonging to a field name.jAgda Get the field names of a record.jAgda0Find all records with at least the given fields.jAgda Get the field types of a record.jAgda/Get the field names belonging to a record type.jAgdaReturns the given record type's constructor name (with an empty range).jAgdaReduce a type and check whether it is a record type. Succeeds only if type is not blocked by a meta var. If yes, return its name, parameters, and definition.jAgdaReduce a type and check whether it is a record type. Succeeds only if type is not blocked by a meta var. If yes, return its name, parameters, and definition. If no, return the reduced type (unless it is blocked).jAgda*Get the original projection info for name.jAgdagetDefType f t? computes the type of (possibly projection-(like)) function f whose first argument has type t . The  parameters for f are extracted from t. Nothing if f is projection(like) but t is not a datarecord axiom type.Precondition: t is reduced. See also: jAgdaThe analogue of Y. If v is a value of record type t with field f, then projectTyped v t f returns the type of f v0. And also the record type (as first result).+Works also for projection-like definitions f9. In this case, the first result is not a record type.Precondition: t is reduced.jAgdaGiven a head and its type, compute the types of the eliminations.jAgdaGoing under one of these does not count as a decrease in size for the termination checker.jAgdaCheck if a name refers to a record which is not coinductive. (Projections are then size-preserving)jAgdaCheck if a type is an eta expandable record and return the record identifier and the parameters.jAgdaTurn off eta for unguarded recursive records. Projections do not preserve guardedness.jAgdaTurn on eta for inductive guarded recursive records. Projections do not preserve guardedness.jAgdaTurn on eta for non-recursive record, unless user declared otherwise.jAgda1Check whether record type is marked as recursive.9Precondition: record type identifier exists in signature.jAgda etaExpandBoundVar i = (, , )%Precondition: The current context is  = A, x:R pars, A where |A| = i and R4 is a eta-expandable record type with constructor c and fields '.Postcondition:  = A, ', A[c '] and   E  :  and   E  : .jAgda #expandRecordVar i  = (, , , ')Precondition:  = A, x:R pars, A where |A| = i and R7 is a eta-expandable record type with constructor c and fields '.Postcondition:  = A, ', A[c '] and   E  :  and   E  : .jAgdaPrecondition: variable list is ordered descendingly. Can be empty.jAgda curryAt v ( (y : R pars) -> B) n = ( v ->   ys C v  (c ys) {- curry -} , v ->   y C v  (p1 y) ... (pm y) {- uncurry -} ,  (ys : As) C B[c ys / y] )where  n = size .jAgdaetaExpand r pars u, computes the eta expansion of record value u at record type r pars.The first argument r? should be the name of an eta-expandable record type. Given /record R : Set where field x : A; y : B; .z : Cand r : R, /etaExpand R [] r = (tel, [R.x r, R.y r, R.z r])where tel8 is the record telescope instantiated at the parameters pars.jAgdaEta expand a record regardless of whether it's an eta-record or not.jAgdaIs the type a hereditarily singleton record type? May return a blocking metavariable.Precondition: The name should refer to a record type, and the arguments should be the parameters to the type.jAgdaReturn the unique (closed) inhabitant if exists. In case of counting irrelevance in, the returned inhabitant contains dummy terms.jAgdaCheck whether a type has a unique inhabitant and return it. Can be blocked by a metavar.jAgdaCheck whether a type has a unique inhabitant (irrelevant parts ignored). Can be blocked by a metavar.jAgdaChecks whether the given term (of the given type) is beta-eta-equivalent to a variable. Returns just the de Bruijn-index of the variable if it is, or nothing otherwise.jAgda(Name of record type (for error message).AgdaHow to fill a missing field.AgdaField names of the record type.Agda6Provided fields with content in the record expression.Agda#Content arranged in official order.jAgda(Name of record type (for error message).AgdaHow to fill a missing field.AgdaField names of the record type.Agda6Provided fields with content in the record expression.Agda#Content arranged in official order.jAgda(Name of record type (for error message).AgdaHow to fill a missing field.AgdaField names of the record type.Agda6Provided fields with content in the record expression.Agda#Content arranged in official order.jAgda*Name of record type (for error reporting).Agda=Function to generate a placeholder for missing visible field.Agda Given fields.AgdaAll record field names with .AgdaGiven fields enriched by placeholders for missing explicit fields.jAgda*Name of record type (for error reporting).Agda=Function to generate a placeholder for missing visible field.Agda Given fields.AgdaAll record field names with .AgdaGiven fields enriched by placeholders for missing explicit fields.jAgda*Name of record type (for error reporting).Agda=Function to generate a placeholder for missing visible field.Agda Given fields.AgdaAll record field names with .AgdaGiven fields enriched by placeholders for missing explicit fields.jAgda"Record type. Need not be reduced.jAgdaHead (record value).Agda Its type.Agda Projection.=bbbbbbjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjj=jjjjjjjjjjjjbjjjjjbjjjjjjjjjjjbjjjjbbjjjjjjjjjjjjjjbjjjjjjjjj Safe-Inferred!!$%&.145789:;ũMSSbbbbSMS Safe-Inferred!!$%&.145789:;SSSSSSHHHHJJKKKKFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFIIIEEEEEEDDDDDDDFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEEEEEEEEEEEEEEEEFECCCDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDEDDDEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHGGGGGGGGGGGGGGGGGGGGGGGHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHHIIIIIHIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIJJIIIJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJJKKKKKKKKKKKKKKKKKKKKKKJJJJJJJJJJKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRRSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSSVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVWWWWWWWWWWWWWWWWWWWWWWWWWWWXXXXXXYYYYYYYYYYYYYYYYYYYYYYYZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZ[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]___________________________________________________```````````````````````````````````````````````````````````````````````````````````````````````````````````aaaaaaa Safe-Inferred!!$%&.145789:;VAgda$Record a function call in the trace.VAgdaReset F' to previous value in the continuation.Caveat: if the last V did not set an V, for example, only set the   with G/, we will revert to the last interesting call.VAgda5Lispify and print the given highlighting information.VAgdaSets the current range (for error messages etc.) to the range of the given object, if it has a range (i.e., its range is not  ).VAgdahighlightAsTypeChecked rPre r m runs m and returns its result. Additionally, some code may be highlighted:If r% is non-empty and not a sub-range of rPre (after   has been applied to both): r/ is highlighted as being type-checked while m0 is running (this highlighting is removed if m completes  successfully).'Otherwise: Highlighting is removed for rPre - r before m runs, and if m completes successfully, then rPre - r) is highlighted as being type-checked.VAgda rPreAgda r VVVVVVVVVV VVVVVVVVVV Safe-Inferred!!$%&.145789:;SAgdaGet the statistics.SAgda)Modify the statistics via given function.SAgdaIncrease specified counter by 1.SAgdaIncrease specified counter by n.SAgdaSet the specified counter to the maximum of its current value and n.SAgdaPrint the given statistics if verbosity "profile.ticks" is given.SSSSSSSSSSSSSSSS Safe-Inferred!!$%&.145789:;!]AgdaA deep view on sizes.]Agda)A de Bruijn index under some projections.]AgdaA useful view on sizes.]AgdaCheck if a type is the [ type. The argument should be reduced.]Agda)Result of querying whether size variable i is bounded by another size.]Agdayes  i : Size< t]AgdaTest whether OPTIONS --sized-types and whether the size built-ins are defined.]Agda+Test whether the SIZELT builtin is defined.]Agda$Add polarity info to a SIZE builtin.]AgdaThe sort of built-in types SIZE and SIZELT.]AgdaThe type of built-in types SIZE and SIZELT.]AgdaThe built-in type SIZE with user-given name.]AgdaThe built-in type SIZE.]Agda The name of SIZESUC.]Agda>Transform list of terms into a term build from binary maximum.]AgdaExpects argument to be reduced.]AgdasizeViewComparable v w checks whether v >= w (then Left) or v <= w (then Right ). If uncomparable, it returns  NotComparable.]AgdasizeViewPred k v decrements v by k (must be possible!).]AgdasizeViewOffset v8 returns the number of successors or Nothing when infty.]Agda'Remove successors common to both sides.]AgdaTurn a size view into a term.]AgdamaxViewCons v ws = max v ws. It only adds v to ws+ if it is not subsumed by an element of ws.]AgdasizeViewComparableWithMax v ws tries to find w in ws that compares with v+ and singles this out. Precondition:  v /= DSizeInv.]AgdaIgnore  in equality test.8]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]8]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]] Safe-Inferred!!$%&.145789:; [AgdaSort primitives.[AgdaThe coinductive primitives.[AgdagetTerm use name looks up name as a primitive or builtin, and throws an error otherwise. The use argument describes how the name is used for the sake of the error message.[Agda2Rewrite a literal to constructor form if possible.]AgdaTries to build a [.]AgdaCheck whether the type is actually an path (lhs D rhs) and extract lhs, rhs, and their type.Precondition: type is reduced.]AgdaNon dependent Path]Agda Revert the 6.Postcondition: type is reduced.]Agda"Get the name of the equality type.]AgdaCheck whether the type is actually an equality (lhs D rhs) and extract lhs, rhs, and their type.Precondition: type is reduced.]Agda Revert the 6.Postcondition: type is reduced.]Agda(Primitives with typechecking constrants.RR[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\]]]]]]]]]]]]]]]]]]]]]]RR[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\]]]]]]]]]]]]]]]]]]]]]] Safe-Inferred"!$%&.145789:; SAgdaLookup the definition of a name. The result is a closed thing, all free variables have been abstracted over.SAgda Version that reports exceptions:SAgda4Lookup the rewrite rules with the given head symbol.SAgdaSignature lookup errors.SAgda8The name is not in the signature; default error message.SAgda0The name is not available, since it is abstract.SAgdaLookup a section telescope.If it doesn't exist, like in hierarchical top-level modules, the section telescope is empty.SAgdaUnless all variables in the context are module parameters, create a fresh module to capture the non-module parameters. Used when unquoting to make sure generated definitions work properly._AgdaAdd a constant to the signature. Lifts the definition to top level._AgdaA combination of _ and L. The  does not need to be supplied._Agda2Set termination info of a defined function symbol._Agda1Set CompiledClauses of a defined function symbol._Agda+Set SplitTree of a defined function symbol._Agda!Modify the clauses of a function._AgdaLifts clauses to the top-level and adds them to definition. Also adjusts the funCopatternLHS field if necessary._Agda#Add a compiler pragma `{-# COMPILE  backend  name  text #-}`_AgdaAdd a section to the signature.The current context will be stored as the cumulative module parameters for this section._AgdaSets the checkpoint for the given module to the current checkpoint._AgdaGet a section.Why Maybe? The reason is that we look up all prefixes of a module to compute number of parameters, and for hierarchical top-level modules, A.B.C say, A and A.B do not exist._AgdaAdd display forms for a name f0 copied by a module application. Essentially if f can reduce to  xs C A.B.C.f vs (by unfolding module application copies (H), then we add a display form A.B.C.f vs ==> f xs _Agda>Module application (followed by module parameter abstraction)._AgdaAdd a display form to a definition (could be in this or imported signature)._AgdaFind all names used (recursively) by display forms of a given name._Agda#Check if a display form is looping._AgdaCan be called on either a (co)datatype, a record type or a (co)constructor._Agda?Does the given constructor come from a single-constructor type?5Precondition: The name has to refer to a constructor._AgdaStandard eliminator for S._AgdaThe computation S sometimes tweaks the returned H, depending on the current  and the  of the H. This variant of S does not perform any tweaks._AgdaGet the original name of the projection (the current one could be from a module application)._Agda%Look up the polarity of a definition._AgdaLook up polarity of a definition and compose with polarity represented by ._Agda!Set the polarity of a definition._Agda-Look up the forced arguments of a definition._Agda*Get argument occurrence info for argument i of definition d (never fails)._Agda Sets the H for the given identifier (which should already exist in the signature)._AgdaReturns a list of length H. If no erasure analysis has been performed yet, this will be a list of s._Agda#add data constructors to a datatype`AgdaGet the mutually recursive identifiers of a symbol from the signature.`Agda.Get the mutually recursive identifiers from a H.`Agda'Set the mutually recursive identifiers.`Agda5Check whether two definitions are mutually recursive.`Agda A functiondatarecord definition is nonRecursive if it is not even mutually recursive with itself.`Agda3Get the number of parameters to the current module.`AgdaCompute the number of free variables of a defined name. This is the sum of number of parameters shared with the current module and the number of anonymous variables (if the name comes from a let-bound module).`Agda7Compute the context variables to apply a definition to.We have to insert the module telescope of the common prefix of the current module and the module where the definition comes from. (Properly raised to the current context.) Example:  module MA  where module MA  where f = ... module MA  where ... MA.MA.f [insert  raised by ] `AgdaInstantiate a closed definition with the correct part of the current context.`Agda'Give the abstract view of a definition.`AgdaEnter abstract mode. Abstract definition in the current module are transparent.`Agda:Not in abstract mode. All abstract definitions are opaque.`Agda?Ignore abstract mode. All abstract definitions are transparent.`AgdaEnter concrete or abstract mode depending on whether the given identifier is concrete or abstract.`AgdaCheck whether a name might have to be treated abstractly (either if we're ` or it's not a local name). Returns true for things not declared abstract as well, but for those ` will have no effect.`AgdaAndreas, 2015-07-01: If the current module is a weak suffix of the identifier module, we can see through its abstract definition if we are abstract. (Then treatAbstractly' returns False). Semigroup (TCM a).1SSSSSSSSSSSSSSSSS^ggggggggggggggggggggggggggggg1SSSSSSSSSSSSSSSSSggggggggggggggggggggggggggggg^S5S6S6g5 Safe-Inferred!!$%&.145789:; fAgdaCreate a concrete name that is not yet in scope. | NOTE: See  chooseName in *Agda.Syntax.Translation.AbstractToConcrete! for similar logic. | NOTE: See withName in +Agda.Syntax.Translation.ReflectedToAbstract for similar logic.^Agda?Look up the abstract name referred to by a given concrete name.^AgdaLook up the abstract name corresponding to a concrete name of a certain kind and/or from a given set of names. Sometimes we know already that we are dealing with a constructor or pattern synonym (e.g. when we have parsed a pattern). Then, we can ignore conflicting definitions of that name of a different kind. (See issue 822.)^AgdaTest if a given abstract name can appear with a suffix. Currently only true for the names of builtin sorts Set and Prop.^AgdaLook up a module in the scope.^Agda'Get the fixity of a not yet bound name.^Agda+Get the polarities of a not yet bound name.^AgdaCollect the fixity/syntax declarations and polarity pragmas from the list of declarations and store them in the scope.^Agda?Get the notation of a name. The name is assumed to be in scope.^AgdaBind a variable.^Agda;Temporarily unbind a variable. Used for non-recursive lets.^Agda.Bind a defined name. Must not shadow anything.^AgdaBind a name. Returns the D" if exists, but does not throw it.^AgdaRebind a name. Use with care! Ulf, 2014-06-29: Currently used to rebind the name defined by an unquoteDecl, which is a . in the body, but a . later on.^AgdaBind a module name.^AgdaBind a qualified module name. Adds it to the imports field of the scope.^Agda Clear the scope of any no names.^AgdaCreate a new scope with the given name from an old scope. Renames public names in the old scope to match the new name and returns the renamings.^Agda*Warn about useless fixity declarations in renaming8 directives. Monadic for the sake of error reporting.^Agda>Check that an import directive doesn't contain repeated names.^AgdaApply an import directive and check that all the names mentioned actually exist.(Monadic for the sake of error reporting.^AgdaTranslation of ImportDirective.^Agda Create a ].^AgdaApply a ].^AgdaTranslation of Renaming.^AgdaOpen a module.^Agda>Open a module, possibly given an already resolved module name.^AgdaOld local scopeAgdaNew local scope^Agda(Restrict search to these kinds of names.AgdaUnless ~., restrict search to match any of these names.AgdaName to be resolvedAgda