D 7      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKL M N O P Q R S T U V W X Y Z [ \ ] ^ _ ` a b c d e f g h i j k l m n o p q r s t u v w x y z { | } ~                                   ! " # $ % & ' ( ) * + , - . / 0 1 2 3 4 5 6 7 8 9 : ; < = > ? @ A BCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnop q r s t u v w x!y!z!{!|!}!~!!!!!!!!!!!!!!!!!!!!!!!!!!!!!""####$$$$$$$%%%%%%%%%%%%%%%%%%%%%%%%%%&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&''(((((((((((((())))***************** * * * * *****++++++++++++++ +!+"+#+$+%+&,',(,),*,+,,,-,.,/,0,1,2,3,4,5,6,7,8,9,:,;,<,=,>,?,@,A,B,C,D,E,F,G,H,I,J,K,L,M,N,O,P,Q,R,S,T,U-V-W-X-Y-Z-[-\-]-^-_-`-a-b-c-d-e-f-g-h-i-j-k-l-m-n-o-p-q-r-s-t-u-v-w-x-y-z-{-|-}-~----------------------------------------------------------------------------------..//00000000000000000000000000000000011111111111111111111 1 1 1 1 1111111111111111111 1!1"1#1$1%1&1'1(1)1*1+1,1-1.1/101112131415161718191:1;1<1=1>1?1@1A1B1C1D1E1F1G1H1I1J1K1L1M1N1O1P1Q1R1S1T1U1V1W1X1Y1Z1[1\1]1^1_1`1a1b1c1d1e1f1g1h1i1j1k1l1m1n1o1p1q1r1s1t1u1v1w1x1y1z1{1|1}1~122222222222222234556666666666666666666667777777777778888888888888888888888888888888888888888888888888889::::::::;;;;;;;;;;<<<<<<<<<<<<<<<< < < < < <<<<<<<<<<<<<<<<<<< <!<"<#<$<%<&<'<(<)<*<+<,<-<.</=0=1=2=3=4=5>6>7>8>9>:>;><>=>>>?>@>A>B>C>D>E>F>G>H>I>J>K>L>M>N>O>P>Q>R>S>T>U>V>W>X>Y>Z>[>\>]>^>_>`>a>b>c>d?e?f?g?h@i@j@k@l@m@n@o@p@q@r@s@t@u@v@w@x@y@z@{@|@}@~@@@@@@AAAAABBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC 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 ,D -D .D /D 0D 1D 2D 3D 4D 5D 6D 7D 8D 9D :D ;D <D =D >D ?D @E AE BE CE DE EE FE GE HE IE JE KE LE MF NF OF PF QF RF SF TF UF VF WF XF YF ZF [F \F ]F ^F _F `F aF bF cF dF eF fF gF hG iG jG kG lG mG nG oG pG qG rG sG tG uG vG wG xG yG zG {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 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 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 0I 1I 2I 3I 4I 5I 6INJ(c) 2014-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportable Trustworthy 7 8 9 7 8 9 7 8 9(c) 2014-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafe::Apply a function to all elements of a container. Returns  : if nothing changed, and Just container otherwise.5Apply functions to both elements of a pair. Returns  : if neither changed, and  Just pair otherwise.KSafe ; < = > ? @ A B C D E F A B C D E F ; < = > ? @ A B C D E F(c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafe(c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafe!"0 G H I J  G H I J (c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafeM KThe preprocessor for  K LThe preprocessor for  L M N O  P Q R K L   M N O   P Q R K L(c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafeKMaps string names to values, allowing for partial key matches and querying.)Insert a value into the Trie. Will call * if a value already exists with that key.)Return all matches with the given prefix.^Given a key, return either an exact match for that key, or all matches with the given prefix.%Return all of the values from a Trie.(c) 2014-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafevThis is the widest word we can have before gmp will fail to allocate and bring down the whole program. According to  ?https://gmplib.org/list-archives/gmp-bugs/2009-July/001538.html the sizes are 2^32-1 for 32-bit, and 2^37 for 64-bit, however experiments show that it's somewhere under 2^37 at least on 64-bit Mac OS X.(c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafe57 (Natural numbers with an infinity element"&Some algebraic properties of interest: W1 * x = x x * (y * z) = (x * y) * z 0 * x = 0 x * y = y * x x * (a + b) = x * a + x * b#&Some algebraic properties of interest: gx ^ 0 = 1 x ^ (n + 1) = x * (x ^ n) x ^ (m + n) = (x ^ m) * (x ^ n) x ^ (m * n) = (x ^ m) ^ n&nSub x y = Just z iff z is the unique value such that Add y z = Just x. ' Rounds down. <y * q + r = x x / y = q with remainder r 0 <= r && r < yWe don't allow H in the first argument for two reasons: 1. It matches the behavior of (I, 2. The well-formedness constraints can be expressed as a conjunction.) Rounds up.  lg2 x = y, iff y" is the smallest number such that  x <= 2 ^ y*nWidth nL is number of bits needed to represent all numbers from 0 to n, inclusive. nWidth x = nLg2 (x + 1).+length ([ x, y .. ] : [_][w])0 We don't check that the second element fits in wY many bits as the second element may not be part of the list. For example, the length of [ 0 .. ] : [_][0] is nLenFromThen 0 1 0, which should evaluate to 1. , length [ x, y .. z ]-Compute the logarithm of a number in the given base, rounded down to the closest integer. The boolean indicates if we the result is exact (i.e., True means no rounding happened, False means we rounded down). The logarithm base is the second argument..CCompute the number of bits required to represent the given integer./gCompute the exact root of a natural number. The second argument specifies which root we are computing.0Compute the the n-th root of a natural number, rounded down to the closest natural number. The boolean indicates if the result is exact (i.e., True means no rounding was done, False means rounded down). The second argument specifies which root we are computing.  !"#$%&'()*+,-./0 !"#$%&'()*+,-./0 !"#$%&'()*+,-./0 !"#$%&'()*+,-./0(c) 2015-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafe56Identifiers, along with a flag that indicates whether or not they're infix operators. The boolean is present just as cached information from the lexer, and never used during comparisons.8Module names are just text.6789:;<=>?@ABCDEFGHI6789:;<=>?@ABCDE89:;67IHGF<=>?@ABCDE6789:;<=>?@ABCDEFGHI (c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafe57ML3Information about an infix expression of some sort.NoperatorO left argumentPright argumrntQoperator precedenceRoperator associativityS Information about associativity.X&Fixity information for infix operatorsYPrint a name in prefix: f a b or (+) a b)Z#Print a name as an infix operator: a + bc*How to display names, inspired by the GHC  Outputable module. Getting a value of  :E from the NameDisp function indicates that the name is not in scope.f%Never qualify names from this module.jMCompose two naming environments, preferring names from the left environment.k Get the format for a name. When  :2 is returned, the name is not currently in scope.l1Produce a document in the context of the current c.m5Fix the way that names are displayed inside of a doc.t.Pretty print an infix expression of some sort.u2Display a numeric values as an ordinar (e.g., 2nd)v9The suffix to use when displaying a number as an oridinalLLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrst1Non-infix leaves are printed with this precedence+pattern to check if sub-thing is also infix"Pretty print this infix expressionuvwxyz{|}~ELMNOPQRSTUVWXYZ[\]^_`abcedfghijklmnopqrstuvwxyz{|}~Lcde_`abfghijklm]^no[\WXYZpqrSTUVLMNOPQRstuvwxyz{|}~9LMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~{6|6}5 (c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafe!"57An empty range.[Caution: using this on the LHS of a use of rComb will cause the empty source to propegate.##L(c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafe57Mvalue, base, number of digitscharacter literal(qualified) identifierstring literalkeywordoperatorsymbolvirtual token (for layout)white space token error token S>The named operators are a special case for parsing types, and  T8 is used for all other cases that lexed as an operator.!.Virtual tokens, inserted by layout processing. UVirtual layout block V7An explicit layout block, expecting this ending token..File that we are working on/Settings for layout processing0Preprocessor settings1Implicit includes2^When we do layout processing should we add a vCurly (i.e., are we parsing a list of things). W=Split out the prefix and name part of an identifier/operator. X'Drop white-space tokens from the input. YeCollapse characters into a single Word8, identifying ASCII, and classes of unicode. This came from: Jhttps://github.com/glguy/config-value/blob/master/src/Config/LexerUtils.hsWhich adapted: >https://github.com/ghc/ghc/blob/master/compiler/parser/Lexer.x S Z [ \ ] ^ _ ` a b c d T      !"#$%&'( e U V)*+ f g h i j k l m n o p,-./0123 q r s t u v w x y z { | } ~  W X Y S ^ T d ] _ Z [ ` \ a b c      !#"$%&'( e U V)+* f g i h j k l m n o p,-./0123 q r s t u v w x y z { | } ~  W X Y*  S Z [ \ ] ^ _ ` a b c d T       !"#$%&'( e U V)*+ f g h i j k l m n o p,-./0123 q r s t u v w x y z { | } ~  W X Y (c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportable TrustworthyB4Returns the tokens in the last position of the input that we processed. White space is removed, and layout processing is done as requested. This stream is fed to the parser.5oReturns the tokens and the last position of the input that we processed. The tokens include whte space tokens.p 45 6i      !#"$%&'()+*,-./012345i54)*+%&'(!"#$      ,-./0123e     45 6 (c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableNone78787878 (c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafe9:;9zThis packages together a type with some names to be used to display the variables. It is used for pretty printing types. *Compute the n-th variant of a name (e.g., a5).  Compute all variants of a name: a, a1, a2, a3, ...@@Expand a list of base names into an infinite list of variations. 9:;<=>? @ANLMNOPQRSTUVWXYZ[\]^_`abcedfghijklmnopqrstuvwxyz{|}~9:;<=>?@A ;9:<=>A@? 9:;<=>? @A(c) 2015-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafe5B%Passes that can generate fresh names.E#Names that originate in the parser.FUnqualified names like x, Foo, or +.GQualified names like Foo::bar or  module::!.H Fresh names generated by a pass.BCDEFGHIJKLMNOP BCDEHGFIJKLEFGHBCDPOIJKLNM BCDEFGHIJKLMNOP(c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafe57 YBuilt-in types.Z  : Num -> Num -> Num[  : Num -> Num -> Num\  : Num -> Num -> Num]  : Num -> Num -> Num^  : Num -> Num -> Num_  : Num -> Num -> Num`  : Num -> Numa  : Num -> Num -> Numb  : Num -> Num -> Numc : Num -> Num -> Num -> Num Example: ([ 1, 5 .. ] :: [lengthFromThen 1 5 b][b]d : Num -> Num -> Num -> Num Example: ,[ 1, 5 .. 9 ] :: [lengthFromThenTo 1 5 9][b]f:Type functions, with their arity and function constructor.YZ[\]^_`abcdefghYZ[\]^_`abcdefYZ[\]^_`abcdefY Z[\]^_`abcdefgh(c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafe!"23457MZs  fin xt  x == 10u  x >= 10v  Arith aw  Cmp axLocation informationy After parsing{  [8] -> [8]| [8] a} Bit~ 10 a infA type variable or synonym 2 + x { x : [8], y : [32] }  ([8], [32])_, just some type.Location information  (ty)  ty + ty  x  _  (x,y,z)  { x = (a,b,c), y = z }  [ x, y, z ]  x : [8]  (x # y)Location informationp <- eSelectors are used for projecting from various components. Each selector has an option spec to specify the shape of the thing that is being selected. Currently, there is no surface syntax for list selectors, but they are used during the desugaring of patterns.UZero-based tuple selection. Optionally specifies the shape of the tuple (one-based).@Record selection. Optionally specifies the shape of the record.=List selection. Optionally specifies the length of the list.  x  0x10  (1,2,3)  { x = 1, y = 2 }  e.l  [1,2,3] [1, 5 .. 117 ]  [1, 3 ...]  [ 1 | x <- xs ]  f x  f `{x = 8}, f`{8}  if ok then e1 else e2  1 + x where { x = 2 }  1 : [8] `(x + 1), x is a type  \x y -> xposition annotation (e)  (Removed by Fixity) a + b  (Removed by Fixity) Literals.0x10 (HexLit 2) "hello";Infromation about the representation of a numeric constant.n-digit binary literaln-digit octal literaloverloaded decimal literaln-digit hex literalcharacter literalpolynomial literal%Export information for a declaration.:Input at the REPL, which can either be an expression or a let statement. Type name Type params ConstructorBindings. Notes:The parser does not associate type signatures and pragmas with their bindings: this is done in a separate pass, after de-sugaring pattern bindings. In this way we can associate pragmas and type signatures with the variables defined by pattern bindings as well.Currently, there is no surface syntax for defining monomorphic bindings (i.e., bindings that will not be automatically generalized by the type checker. However, they are useful when de-sugaring patterns. Defined thing Parameters DefinitionOptional type sigInfix operator?Optional fixity infoOptional pragmasIs this a monomorphic bindingOptional doc string&The list of names following an import.INVARIANT: All of the Name@ entries in the list are expected to be unqualified names; the QName or H% constructors should not be present.An import declaration.#A string with location information.(An identifier with location information.!A name with location information.&The fixity used when none is provided.@Add a binding name to the export list, if it should be exported.&Check to see if a binding is exported.EAdd a type synonym name to the export list, if it should be exported.+Check to see if a type synonym is exported.3Display the thing selected by the selector, nicely.Conversational3 printing of kinds (e.g., to use in error messages)pqrstuvwxyz{|}~       !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`a68?@ABCSTUVBCDEHGFIJKLpqrystuvwxz{|}~     6?@ABC8EFGHKLIJBCDSTUVz{|}~rstuvwxy     pqwpqrstuvwxyz{|}~        !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`a(c) 2015-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportable Trustworthy !"579;<=IEA mapping from an identifier defined in some module to its real name.)A monad for easing the use of the supply. INVARIANT: this field uniquely identifies a name for one session with the Cryptol library. Names are unique to their binding site. *Information about the origin of this name. The name of the identifier ?The associativity and precedence level of infix operators.  :* indicates an ordinary prefix operator. Where this name was defined/Information about the binding site of the name.2This name refers to a declaration from this module+This name is a parameter (function or type)Compare two names lexically.5Compare two names by the way they would be displayed. Figure out how the name should be displayed, by referencing the display function in the environment. NOTE: this function doesn't take into account the need for parenthesis.9Pretty-print a name with its source location information.)Retrieve the next unique from the supply.This should only be used once at library initialization, and threaded through the rest of the session. The supply is started at 0x1000 to leave us plenty of room for names that the compiler needs to know about (wired-in constants)."Make a new name for a declaration.Make a new parameter name.vIt's assumed that we're looking things up that we know already exist, so this will panic if it doesn't find the name.vIt's assumed that we're looking things up that we know already exist, so this will panic if it doesn't find the name.7        (        (c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafe!"579:;MC Mutually recursive declarations!Non-recursive declaration#Hdo we need this type? it seems like it can be computed from the expr&"List value (with type of elements)' Tuple value( Record value)Elimination for tuplerecordlist* If-then-else+?List comprehensions The type caches the type of the expr.,Use of a bound variable-Function Value.Type application/Function application0Function value1Proof abstraction. Because we don't keep proofs around we don't need to name the assumption, but we still need to record the assumption. The assumption is the P0 term, which should be of kind n.2RIf `e : p => t`, then `EProofApp e : t`, as long as we can prove p.We don't record the actual proofs, as they are not used for anything. It may be nice to keep them around for sanity checking.3if e : t1, then cast e : t2 as long as we can prove that 't1 = t2'. We could express this in terms of a built-in constant. `cast :: {a,b} (a =*= b) => a -> b`4Using the constant is a bit verbose though, because we end up with both the source and target type. So, instead we use this language construct, which only stores the target type, and the source type can be reconstructed from the expression.jAnother way to think of this is simply as an expression with an explicit type annotation.71-1 constants.8Numbers9Inf:Bit; [_] _< _ -> _=  (_, _, _)>user-defined, T?Built-in type constants.Predicate symbols.@ _ == _A _ /= _B _ >= _C fin _DHas sel type field does not appear in schemasE Arith _F Cmp _GType constants.KType variables.LAUnique, kind, ids of bound type variables that are in scope The ]. is a description of how this type came to be.N;The type is "simple" (i.e., it contains no type functions).O#The type is supposed to be of kind nPLThe internal representation of types. These are assumed to be kind correct.QType constant with argsRType variable (free or bound)SThis is just a type annotation, for a type that was written as a type synonym. It is useful so that we can use it to report nicer errors. Example: `TUser T ts t` is really just the type t7 that was written as `T ts` by the user. T Record typeUType parameters.WParameter identifierXKind of parameterYName from source, if any.Z Named records` Type synonym.bNamec ParametersdEnsure body is OKe Definitionf The types of polymorphic values.kKinds, classify types.pA Cryptol module.ESplit up repeated occurances of the given binary type-level function.Make a function type."Eliminate outermost type synonyms.Equality for numeric types.+Make a greater-than-or-equal-to constraint.A Has1 constraint, used for tuple and record selection.Make multiplication type.Make addition type.Make a min type.NConstruct a primitive, given a map to the unique names of the Cryptol module.Make an expression that is  % pre-applied to a type and a message. !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~YZ[\]^_`abcd !"$#%/,')&+*4(-.012356789:;<=>?@ABCDEFGHJIKLMNOPRQSTUVYXWZ[\]^_`abcdefghijkomlnpqrtwsuvxyz{|}~pqrstuvwklmnofghij`abcdeZ[\]^_UVWXYxPQRSTONKLMGHIJ?@ABCDEF789:;<=>56%&'()*+,-./01234"#$ !yz{|}~YZ[\]^_`abcd !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~o554476(c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafe0)Panic from an Eval context.*3A sequencing operation has gotten an invalid index.+ For things like `(inf) or `(0-1),For division by 0.-For when we know that a word is too wide and will exceed gmp's limits (though words approaching this size will probably cause the system to crash anyway due to lack of memory).For  #$%&'()*+,-./0 #&($%')*+,-.)#$%&'(0/*+,-. #$%&'()*+,-./0(c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafe2579;<=M3NOTE this assumes that the sequence of bits is big-endian and finite, so the first element of the list will be the most significant bit.4NOTE this produces a list of bits that represent a big-endian word, so the most significant bit is the first element of the list.<jAn evaluated type of kind *. These types do not contain type variables, type synonyms, or type functions.? inftD8Generic value type, parameterized by bit and word types.NJwidth, value Invariant: The value must be within the range 0 .. 2^width-1WSmart constructor for N!s that checks for the width limit_Create a packed word of n bits.aA type lambda that expects a Type of kind *.bA type lambda that expects a Type of kind #.cGenerate a stream.eThis is strict!fConstruct either a finite sequence, or a stream. In the finite case, record whether or not the elements were bits, to aid pretty-printing.gConstruct one of: * a word, when the sequence is finite and the elements are bits * a sequence, when the sequence is finite but the elements aren't bits * a stream, when the sequence is not finitehNOTE: do not use this constructor in the case where the thing may be a finite, but recursive, sequence.hExtract a bit value.iExtract a sequence.kExtract a packed word.m3Turn a value into an integer represented by w bits.n Extract a function from a value.o,Extract a polymorphic function from a value.p,Extract a polymorphic function from a value.qExtract a tuple from a value.rExtract a record from a value.sLookup a field in a record.tdGiven an expected type, returns an expression that evaluates to this value, if we can determine it.AXXX: View patterns would probably clean up this definition a lot.F23456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^ Bit-widthValue Masked result_`abcdefghijklmnopqrstuvwC23456789:;<=>?B@ACDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstFPQRSTUVNOWDEFGHIJKLMC<=>?@ABXw789:;YZ[\56v]234^u_`abcdefghijklmnopqrst/23456789:;<=>?@ABCD EFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvw(c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableNone9;<=I /<=>?B@ADEFGHIJKLMPUV`abcdfhiknopqrs/<=>?@ABPUDEFGHIJKLM`abcdfVhnopqrsik (c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafe29;<=?  (c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafe!"9:;MMakes a substitution out of a list. WARNING: We do not validate the list in any way, so the caller should ensure that we end up with a valid (e.g., idempotent) substitution.Apply a substitution. Returns  : if nothing changed.3Pick types for unconstrained unification variables.1Apply the substitution to the keys of a type map.3WARNING: This instance assumes that the quantified variables in the types in the substitution will not get captured by the quantified variables. This is reasonable because there should be no shadowing of quantified variables but, just in case, we make a sanity check and panic if somehow capture did occur. %% (c) 2015-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafe expected, actualexpected a mono type, got this $Validate a type, returning its kind. 8Check that the type is valid, and it has the given kind. "Check that this is a valid schema. zCheck that the expression is well-formed, and compute its type. Reports an error if the expression is not of a mono type. ACheck that the expression is well-formed, and compute its schema. 2Check if the one type is convertible to the other. KCheck a declaration. The boolean indicates if we should check the sigantureC                   ! " # $ % & ' ( ) * +%                   ! " # $ % & ' ( ) * +(c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafe$2MXThe most general unifier is a substitution and a set of constraints on bound variables. (c) 2014-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafe!"5<=>Replaces occurances of the name with the expression. Returns  :) if there were no occurances of the name.2Expressions, representing Cryptol's numeric types.KPropopsitions, representing Cryptol's numeric constraints (and a bit more)., The constant 0.- The constant 1.. The constant 2./ The constant infinity.0+Make a conjucntion of the given properties.1+Make a disjunction of the given properties.2&Compute all expressions in a property.37Compute the immediate sub-expressions of an expression.4Rebuild an expression, using the top-level strucutre of the first expression, but the second list of expressions as sub-expressions.5,Compute the free variables in an expression.6,Compute the free variables in a proposition.:Pretty print a name. ,/An infinite list of names, for pretty prinitng.;"Pretty print a top-level property.<<Pretty print a proposition, in the given precedence context.=,Pretty print an expression at the top level.><Pretty print an expression, in the given precedence context.?$Pretty print an experssion with ifs.@$Pretty print an experssion with ifs.CEThis is used in the simplification to "apply" substitutions to Props.A      !"#$%&'()*+,-./0123456789: ,;<=>?@ABCDEF=     &!('%$ "#)*+,-./0123456789:;<=>?@=)*+: !"#$%&'(26;<,-./01345=>    @? 879#        !"#$%&'()*+,-./0123456789: ,;<=>?@ABCDEF 66784 4!4"4#4$3%2(c) 2015-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafeV$Simplify an expression, if possible.W4Perform simplification from the leaves up. Returns  : if there were no changes.]CMake a simplification step, assuming the expression is well-formed. STUVWXYZ[\] STUVWXYZ[\] VWSTUXYZ[\] STUVWXYZ[\](c) 2015-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafe9;M - Apply a substituition to an atom .False /True 0Negation 1And 2Or 3'If-then-else with non-atom at decision. 4Atoms to propositions. 5Implementation of  6 7Implementation of  8 9Implementation `e1 > e2`. :Implementation of  ;Implementation of `e == inf` < Eliminate /, except at the top level. = > ? @ A_ - B` . / 0 1 2 C 3 4 5 7 9 : ; D E F G H I <a_`_` = > ? @ A_ - B` . / 0 1 2 C 3 4 5 7 9 : ; D E F G H I <a(c) 2014-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafecBA condition ensure that the given *basic* proposition makes sense.dGenerate a property ensuring that the expression is well-defined. This might be a bit too strict. For example, we reject things like max inf (0 - 1)*, which one might think would simplify to inf.cdcdcdcd(c) 2014-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafe9;Me!Simplify a property, if possible.f!Simplify a property, if possible. JA single simplification step. KZRebalance parens, and arrange conjucts so that we can transfer information left-to-right. L[Rebalance parens, and arrange disjuncts so that we can transfer information left-to-right. M6Identify propositions that are suiatable for inlining. N7Rearrange proposition for conjuctions and disjunctions.Vinformation left-to-right, so we put proposition with information content on the left. OSimplification of $'. Assumes arranged conjucntions. See  K. PSimplification of %'. Assumes arranged disjunctions. See  L Q<Propagate the fact that the variable is known to be finite ( R) or not-finite ( S8). Note that this may introduce new expression redexes. T Negation. USimplificaiton for :== VSimplificatoin for :> WAttempt to simplify a fin& constraint. Assumes a defined input. XConstant > expression YExpression > constantg'Simplify only the Expr parts of a Prop.h1Simplify only the Expr parts of a Prop. Returns  : if there were no changes. ZOur goal is to bubble inf terms to the top of Return. [VMake an expression that should work ONLY on natural nubers. Eliminates occurances of inf{. Assumes that the two input expressions are well-formed and finite. The expression is constructed by the given function. \ef J K L M N ] ^ O P Q T U V W _ X Ygh Z [efghefgh \ef J K L M N ] ^ O P Q T U V W _ X Ygh Z [(c) 2014-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafe!" `,Substitution does not affect the expression. a8The expression was updated and, maybe, it became linear.j,Factor-out non-linear terms, by naming them.kBApply a substituin to the non-linear expression database. Returns  :, if nothing was affected. Otherwise returns  bC, and a substitution for non-linear expressions that became linear.The definitions of NL terms do not contain other named NL terms, so it does not matter if the substitution contains bindings like _a = e.nThere should be no bindings that mention NL term names in the definitions of the substition (i.e, things like x = _a are NOT ok).mGet the known non-linear terms.n0The initial state for the linearization process. c:Apply the substituint to all non-linear bindings. Returns  :, if nothing was affected. Otherwise returns  bO, and a substituion mapping names that used to be non-linear but became linear.~Note that we may return `Just empty`, indicating that some non-linear expressions were updated, but they remained non-linear. d+Is the top-level operator a non-linear one.i e f g h i j k ` a l m n o pjkl qmn c r d s t u v wijklmnjimnkli e f g h i j k ` a l m n o pjkl qmn c r d s t u v w (c) 2014-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafepqrstuvwpqrstuvwpqrstuvwpqrstuvw!(c) 2015-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafeM zlower bound (inclusive){Qupper bound (inclusive) If there is no upper bound, than all *natural* numbers.!Only meaningful for numeric types1What we learn about variables from a single prop.Returns  R, when the intervals definitely overlap, and  S otherwise.Intersect two intervals, yielding a new one that describes the space where they overlap. If the two intervals are disjoint, the result will be  :. Any valueAny finite valueExactly this value xyz{|}~ xy{z|}~ |}~xyz{xyz{|}~"(c) 2014-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafe$MGiven a typing environment and an expression, compute the type of the expression as quickly as possible, assuming that the expression is well formed with correct type annotations. xBYields the return type of the selector on the given argument type. x x#(c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafe6All ways to split a type in the form: `a + t1`, where a is a variable.5Check if we can express a type in the form: `a + t1`.<Check if we can express a type in the form: `k + t1`, where kw is a constant > 0. This assumes that the type has been simplified already, so that constants are floated to the left. <Check if we can express a type in the form: `k * t1`, where kv is a constant > 1 This assumes that the type has been simplified already, so that constants are floated to the left. $(c) 2014-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafe y8Assumes simplified, linear, finite, defined expressions.$Assumes simplified, linear, defined..The name of a variable in the SMT translation.5The name of a boolean variable, representing `fin x`.Get the value for the given name. * Assumes that we are in a SAT state (i.e., there is a model) * Assumes that the name is in the model #Get the values for the given names. zuConvert a bunch of improving equations into an idempotent substitution. Assumes that the equations don't have loops.wGiven a model, compute an improving substitution, implied by the model. The entries in the substitution look like this:x = A variable x must equal constant Ax = y variable x must equal variable y x = A * y + B, (coming soon) variable x is a linear function of y, A and B are natural numbers.We are mostly interested in improving unification variables. However, it is also useful to improve skolem variables, as this could turn non-linear constraints into linear ones. For example, if we have a constraint  x * y = z, and we can figure out that x4 must be 5, then we end up with a linear constraint  5 * y = z. {"Try to prove the given expression. |Try to prove the given expression. If we fail, we try to give a counter example. If the answer is unknown, then we return an empty counter example. }lIs this the only possible value for the constant, under the current assumptions. Assumes that we are in a Sat state. Returns  :~ if the variables must always match the given value. Otherwise, we return a counter-example (which may be empty, if uniknown) ~mDo these two variables need to always be the same, under the current assumptions. Assumes that we are in a Sat state. Try to find a linear relation between the two variables, based on two observed data points. NOTE: The variable being defined is the SECOND name. ZCompute a linear relation through two concrete points. Try to find a relation of the form  y = a * x + b. Depending on the signs of a and b+, we need additional checks, to ensure tha  a * x + b is valid.9y1 = A * x1 + B y2 = A * x2 + B (y2 - y1) = A * (x2 - x1))A = (y2 - y1) / (x2 - x1) B = y1 - A * x1 y  z { | } ~ &Definition in terms of this variable. Define this variable. Values in one model (x,y) Values in another model (x,y) aEither nothing, or an improving expression, and any additional obligations  First point  Second point (A,B)  y  z { | } ~  %(c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafe!"#The property as entered by the user#The property as entered by the user@A test result is either a pass, a failure due to evaluating to False;, or a failure due to an exception raised during evaluationpApply a testable value to some arguments. Note that this function assumes that the values come from a call to P (i.e., things are type-correct). We run in the IO monad in order to catch any  EvalErrors.Given a (function) type, compute all possible inputs for it. We also return the total number of test (i.e., the length of the outer list. QGiven a fully-evaluated type, try to compute the number of values in it. Returns  : for infinite types, user-defined types, polymorhic types, and, currently, function spaces. Of course, we can easily compute the sizes of function spaces, but we can't easily enumerate their inhabitants. TReturns all the values in a type. Returns an empty list of values, for types where  returned  :.   &(c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafe!"57MHThe resulting interface generated by a module that has been typechecked.,Generate an Iface from a typechecked module.$Produce a PrimMap from an interface.NOTE: the map will expose both public and private names.   '(c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafe9:;<=MtNote that this assumes that this pass will be run only once for each module, otherwise we will get name collisions. Produce a fresh top-level name. mNot really any distinction between global and local, all names get the module prefix added, and a unique id.     ((c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafe579;.Bind a variable in the evaluation environment.%Lookup a variable in the environment.$Bind a type variable of kind # or *.Lookup a type variable.    )(c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafeM#Evaluation for types (kind * or #).$Evaluation for value types (kind *).AReduce type functions, raising an exception for undefined values.*(c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafeThe names defined by a newtype.IThe names defined and used by a group of mutually recursive declarations.4The names defined and used by a single declarations.The names defined and used by a single declarations in such a way that they cannot be duplicated in a file. For example, it is fine to use xH on the RHS of two bindings, but not on the LHS of two type signatures./The names defined and used by a single binding. The names used by an expression.)The names defined by a group of patterns.HThe names defined by a pattern. These will always be unqualified names.&The names defined and used by a match.<The names defined and used by an arm of alist comprehension.;Remove some defined variables from a set of free variables.]Given the set of type variables that are in scope, compute the type synonyms used by a type.NThe type names defined and used by a group of mutually recursive declarations.8The type names defined and used by a single declaration. (The type names used by a single binding. %The type names used by an expression. !The type names used by a pattern.The type names used by a match.%The type names used by a type schema.The type names used by a prop.8Compute the type synonyms/type variables used by a type.                    +(c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafe!"579;M $Eliminate all patterns in a program. Given a pattern, transform it into a simple pattern and a set of bindings. Simple patterns may only contain variables and type annotations. /Add annotations to exported declaration groups.XXX: This isn't quite right: if a signature and binding have different export specifications, this will favor the specification of the binding. This is most likely the intended behavior, so it's probably fine, but it does smell a bit. GAdd annotations, keeping track of which annotation are not yet used up. Add annotations, keeping track of which annotation are not yet used up. The exception indicates which declarations are no longer needed. .Add pragma/signature annotations to a binding. Check for multiple signatures. .Does this declaration provide some signatures? .Does this declaration provide some signatures? 1Does this declaration provide fixity information? ?Does this top-level declaration provide a documentation string? 5Pick a new name, to be used when desugaring patterns. Record an error.7   !"  +     !",(c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafe !"234579:;M("Things that define exported names.1Expr renaming environment2Type renaming environment3#Expression-level fixity environment4iMerge two name maps, collapsing cases where the entries are the same, and producing conflicts otherwise.5Generate a mapping from 6 to  for a given naming environment.68Generate a display format based on a naming environment.79Produce sets of visible names for types and declarations.rNOTE: if entries in the NamingEnv would have produced a name clash, they will be omitted from the resulting sets.8Qualify all symbols in a / with the given prefix.:$Singleton type renaming environment.;*Singleton expression renaming environment.<9Like mappend, but when merging, prefer values on the lhs.> Generate a / using an explicit supply.?jInterpret an import in the context of an interface, to produce a name environment for the renamer, and a c for pretty-printing.@cGenerate a naming environment from a declaration interface, where none of the names are qualified.A0The naming environment for a single declaration.DThe naming environment for a single module. This is the mapping from unqualified names to fully qualified names with uniques.E5Generate the naming environment for a type parameter.FIntroduce the nameG|Produce a naming environment from an interface file, that contains a mapping only from unqualified names to qualified ones.HXGenerate a type renaming environment from the parameters that are bound by this schema.(&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLM&'()*+,-./0123456789:;<=>?@(/0123M456789:;<=-.>*+,L()KJIH?@&'GFEDCBA&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLM-(c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafe$579:;.XGInformation about how a constraint came to be, used in error reporting.Y%Computing shape of list comprehensionZUse of a split pattern[+A type signature in a pattern or expression\ Instantiation of this expression`#Just defaulting on the command lineaUse of a partial type function.c/Constraints arising from type-checking patternsd?Various errors that might happen during type checking/inferencee Just say thisfExpected kind, inferred kindgMNumber of extra parameters, kind of result (which should not be of the form _ -> _)h$Type-synonym, number of extra paramsi&Type-synonym, number of missing paramsj2Type parameters with the same name (in definition)k&Multiple definitions for the same namel+The type synonym declarations are recursivem*Use of a type synonym that was not definedn&Use of a variable that was not definedo7Attempt to explicitly instantiate a non-existent param.p0Multiple definitions for the same type parameterqExpected type, inferred typer'Unification results in a recursive typeskA constraint that we could not solve The boolean indicates if we know that this constraint is impossible.t3A constraint (with context) that we could not solveuVType wild cards are not allowed in this context (e.g., definitions of type synonyms).vLUnification variable depends on quantified variables that are not in scope.wgQuantified type variables (of kind *) need to match the given type, so it does not work for all types.xRThe given constraints causes the signature of the function to be not-satisfiable.yFToo many positional type arguments, in an explicit type instantiationSolved, assuming the sub-goals.We could not solve the goal.The goal can never be solved.GDelayed implication constraints, arising from user-specified type sigs.+Signature that gave rise to this constraint,Something that we need to find evidence for.What it is about$Part of source code that caused goalWhat needs to be proved*The types of variables in the environment. Known typePart of current SCCThe SMT solver to invoke*Additional arguments to pass to the solver$How verbose to be when type-checkingFor use in error messagescUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~OUVWXYZ[\]^_`abcdfqneghijklmoprstuvwxyz{|}~c|}~defghijklmnopqrstuvwxyz{XYZ[\]^_`abcUVW&UVWX YZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~.(c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafeM1Solve class constraints. If not, then we return  :. If solved, ther we return  b a list of sub-goals. 6Solve an original goal in terms of the give sub-goals. 3Solve an Arith constraint by instance, if possible. eSolve an Arith constraint for a sequence. The type passed here is the element type of the sequence. Solve Cmp constraints.vAdd propositions that are implied by the given one. The result contains the orignal proposition, and maybe some more.  /(c) 2015-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafeM0(c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafe!"9:M% OVariables declared in this scope (not counting the ones from previous scopes). These are the non-linear terms mentioned in the assertions that are currently asserted (including ones from previous scopes). Either a type variable that makes the asserted properties unsatisfiable (due to a broken interval), or the current set of intervals for type variables. If a variable is not in the interval map, its value can be anything.1This includes all intervals from previous scopes. MThis is the set of currently-asserted cryptol properties only in this scope.6This includes all asserted props from previous scopes. 7Keeps track of declared variables and non-linear terms.6An SMT solver, and some info about declared variables. The actual solver ?Information about declared variables, and assumptions in scope. For debugging and A should be logically equivalent, to each other, and to whatever a represents (usually a is a ).;Optional data to associate with prop. Often, the original # from which the prop was extracted.Fully simplified: may mention ORs, and named non-linear terms. These are what we send to the prover, and we don't attempt to convert them back into Cryptol types. A version of the proposition where just the expression terms have been simplified. These should not contain ORs or named non-linear terms because we want to import them back into Crytpol types. *We use this to remember what we simplified:Class goals go on the left, numeric goals go on the right.Simplify a bunch of well-defined properties. * Eliminates properties that are implied by the rest. * Does not modify the set of assumptions. Simplify easy less-than-or-equal-to and equal-to goals. Those are common with long lists of literals, so we have special handling for them. In particular:Reduce goals of the form  (a >= k1, a >= k2, a >= k3, ...) to a >= max (k1, k2, k3, ...) , when all the k's are constant.Eliminate goals of the form ki >= k2, when k2 is leq than k1.Eliminate goals of the form a >= 0.4NOTE: This assumes that the goals are well-defined.Add the given constraints as assumptions. * We assume that the constraints are well-defined. * Modifies the set of assumptions.Given a list of propositions that together lead to a contradiction, find a sub-set that still leads to a contradiction (but is smaller).ZAttempt to find a substituion that, when applied, makes all of the given properties hold. \Given a *simplified* prop, separate linear and non-linear parts and return the linear ones.  No scopes. %Check if a name is any of the scopes. Add a name to a scope. ?Add an assertion to the current scope. Returns the linear part. Enter a scope.  Exit a scope. lAll declared names, that have not been "marked". These are the variables whose values we are interested in. All known non-linear terms.3Execute a computation with a fresh solver instance.,Execute a computation in a new solver scope. Declare a variable. MAdd an assertion to the current context. INVARIANT: Assertion is simplified. MAdd an assertion to the current context. INVARIANT: Assertion is simplified. (Try to prove a property. The result is  R0 when we are sure that the property holds, and  S% otherwise. In other words, getting  S5 *does not* mean that the proposition does not hold.Check if the current set of assumptions is satisfiable, and find some facts that must hold in any models of the current assumptions.Returns  :E if the currently asserted constraints are known to be unsatisfiable.JReturns `Just (su, sub-goals)` is the current set is satisfiable. * The sum is a substitution that may be applied to the current constraint set without loosing generality. * The  `sub-goals`Z are additional constraints that must hold if the constraint set is to be satisfiable. Assuming that we are in a satisfiable state, try to compute an improving substitution. We also return additional constraints that must hold for the currently asserted propositions to hold.I         4             1(c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafe!"57JWFThis is what's returned when we lookup variables during kind checking.Locally bound variable.An outer binding.kinds of (known) vars.lazy map, with tyvars.are type-wild cards allowed?"Read-write component of the monad.Collected errorsCollected warningsAccumulated substitution|These keeps track of what existential type variables are available. When we start checking a function, we push a new scope for its arguments, and we pop it when we are done checking the function body. The front element of the list is the current scope, which is the only thing that will be modified, as follows. When we encounter a existential type variable: 1. we look in all scopes to see if it is already defined. 2. if it was not defined, we create a fresh type variable, and we add it to the current scope. 3. it is an error if we encounter an existential variable but we have no current scope.FSelector constraints that have been solved (ref. iSolvedSelectorsLazy) Ordinary constraints *Tuple/record projection constraints. The  Z is the "name" of the constraint, used so that we can name it solution properly.  !Read-only component of the monad.Source code being analysed"Type of variable that are in scopeType variable that are in scopeType synonyms that are in scopeNewtype declarations in scope3NOTE: type synonyms take precedence over newtype. The reason is that we can define local type synonyms, but not local newtypes. So, either a type-synonym shadows a newtype, or it was declared at the top-level, but then there can't be a newtype with the same name (this should be caught by the renamer).KNOTE: This field is lazy in an important way! It is the final version of  in , and the two are tied together through recursion. The field is here so that we can look thing up before they are defined, which is OK because we don't need to know the results until everything is done.When this flag is set to true, bindings that lack signatures in where-blocks will never be generalized. Bindings with type signatures, and all bindings at top level are unaffected.The results of type inference.We found some errors Type inference was successful.!*This is used for generating various names.%&Information needed for type inference.'Location of program source(Variables that are in scope)Type synonyms that are in scope*Newtypes in scope+Private state of type-checker,=Should local bindings without signatures be monomorphized?-!Options for the constraint solver.The mapping from Ident to 5, for names that the typechecker needs to refer to./$The supply for fresh name generation06The initial seeds, used when checking a fresh program.3eThe monadic computation is about the given range of source code. This is useful for error reporting.51This is the current range that we are working on.6Report an error.9IRetrieve the mapping between identifiers and declarations in the prelude.;eRecord some constraints that need to be solved. The string explains where the constraints came from.<^The constraints are removed, and returned to the caller. The substitution IS applied to them. ='Add a bunch of goals that need solving.>UCollect the goals emitted by the given sub-computation. Does not emit any new goals.?;Record a constraint that when we select from the first type, we should get a value of the second type. The returned function should be used to wrap the expression from which we are selecting (i.e., the record or tuple). Plese note that the resulting expression should not be forced before the constraint is solved.@)Add a previously generate has constrainedAGet the HasJ constraints. Each of this should either be solved, or added back using @.B@Specify the solution (`Expr -> Expr`) for the given constraint ( ).DGenerate a new name for a goal.E"Generate a new free type variable.FTGenerate a new free type variable that depends on these additional type parameters.G"Generate a new free type variable.HKGenerate an unknown type. The doc is a note about what is this type about.I8Record that the two types should be syntactically equal.JIApply the accumulated substitution to something with free type variables.K5Get the substitution that we have accumulated so far.L$Add to the accumulated substitution.MTVariables that are either mentioned in the environment or in a selector constraint.NLookup the type of a variable.O Lookup a type variable. Return  :_ if there is no such variable in scope, in which case we must be dealing with a type constant.P(Lookup the definition of a type synonym.Q"Lookup the definition of a newtypeRCheck if we already have a name for this existential type variable and, if so, return the definition. If not, try to create a new definition, if this is allowed. If not, returns nothing.S6Returns the type synonyms that are currently in scope.T3Returns the newtype declarations that are in scope.U6Get the set of bound type variables that are in scope.V9Return the keys of the bound variables that are in scope.WRetrieve the value of the  `mono-binds` option.XWe disallow shadowing between type synonyms and type variables because it is confusing. As a bonus, in the implementation we don't need to worry about where we lookup things (i.e., in the variable or type synonym environment. YHThe sub-computation is performed with the given type parameter in scope.[FThe sub-computation is performed with the given type-synonym in scope.]BThe sub-computation is performed with the given variable in scope.`CThe sub-computation is performed with the given variables in scope.aCThe sub-computation is performed with the given variables in scope.bVThe sub-computation is performed with the given type synonyms and variables in scope.clPerform the given computation in a new scope (i.e., the subcomputation may use existential type variables).d.The arguments to this function are as follows:H(type param. name, kind signature (opt.), a type representing the param)The type representing the parameter is just a thunk that we should not force. The reason is that the type depnds on the kind of parameter, that we are in the process of computing.fAs a result we return the value of the sub-computation and the computed kinds of the type parameters. e*Check if a name refers to a type variable.f'Are type wild-cards OK in this context?gReports an error.i8Generate a fresh unification variable of the given kind.j(Lookup the definition of a type synonym.k#Lookup the definition of a newtype.m6Replace the given bound variables with concrete types.nRecord the kind for a local type variable. This assumes that we already checked that there was no other valid kind for the variable (if there was one, it gets over-written). o@The sub-computation is about the given range of the source code.      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcd See commentefghijklmnopqrstuvwxyUVWXYZ[\]^_`abcdfqneghijklmoprstuvwxyz{|}~      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopq%&'()*+,-./!"#$0 1     yxwvu23456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abctsrdefghijklmnopqU       !"#$% &'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxy2(c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafe9;`Check for duplicate and recursive type synonyms. Returns the type-synonyms in dependency order.IAssociate type signatures with bindings and order bindings by dependency.Given a list of declarations, annoted with (i) the names that they define, and (ii) the names that they use, we compute a list of strongly connected components of the declarations. The SCCs are in dependency order. gCombine a bunch of definitions into a single map. Here we check that each name is defined only onces. gCombine a bunch of definitions into a single map. Here we check that each name is defined only onces. *Identify multiple occurances of something.  3(c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafe Instantiate an expression of the given polymorphic type. The arguments that are provided will be instantiated as requested, the rest will be instantiated with fresh type variables.Note that we assume that type parameters are not normalized. Generally, the resulting expression will look something like this: ECast (EProofApp (ETApp e t)) t1awhere - There will be one `ETApp t` for each insantiated type parameter; - there will be one 26 for each constraint on the schema; - there will be 33 if we had equality constraints from normalization.  4(c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafeM Compute the type of a field based on the selector. The given type should be "zonked" (i.e., substitution was applied to it), and (outermost) type synonyms have been expanded.Solve has-constraints.  5(c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafeM(c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafe57M WWARNING: This is a bit of a hack. It is used to represent anonymous type applications. Generate a signature and a primitive binding. The reason for generating both instead of just adding the signature at this point is that it means the primitive declarations don't need to be treated differently in the noPat pass. This is also the reason we add the doc to the TopLevel constructor, instead of just place it on the binding directly. A better solution might be to just have a different constructor for primitives. Fix-up the documentation strings by removing the comment delimiters on each end, and stripping out common prefixes on all the remaining lines.4                             0                         /                               6(c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportable Trustworthy" /023459:;<=?@ABCDFIJKMNOQRT ! " # $ % & ' ( ) * + , - . / 0 1 2 3 4 5 6 7 8 9 : ; < = > ? @ A B C D E F G H I J K L M N O P Q R S T U V W X Y Z [ \ ] ^ _ ` a b c d e f g h i j k l m n o p q r s t u v w x y z { | } ~                            ! " # $ % & ' ( ) * + , - . / 0 1 2 3 4 5 6 7 8 9 : ; < = > ? @ A B C D E F G H I J K L M N O P Q R S T U V W X Y Z [ \ ] ^ _ ` a b c d e f g h i j k l m n o p q r s t u v w x y z { | } ~        !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~% )+*,-./0123%)*+,-./0123  ! " # $ % & ' ( ) * + , - . / 0 1 2 3 4 5 6 7 8 9 : ; < = > ? @ A B C D E F G H I J K L M N O P Q R S T U V W X Y Z [ \ ] ^ _ ` a b c d e f g h i j k l m n o p q r s t u v w x y z { | } ~                            ! " # $ % & ' ( ) * + , - . / 0 1 2 3 4 5 6 7 8 9 : ; < = > ? @ A B C D E F G H I J K L M N O P Q R S T U V W X Y Z [ \ ] ^ _ ` a b c d e f g h i j k l m n o p q r s t u v w x y z { | } ~        !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~ #9  $9 7(c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafe!"57Files that have been loaded&The path that includes are relative toGGet the absolute directory name of a file that contains cryptol source.Run a  action with a different include path. The argument is expected to be the path of a file that contains cryptol source, and will be adjusted with getIncPath.6Adjust an included file with the current include path. Raise an  error.Push a path on the stack of included files, and run an action. If the path is already on the stack, an include cycle has happened, and an error is raised.NLift an IO operation, with a way to handle the exception that it might throw.Like B, but tries to collect as many errors as possible before failing.Remove includes from a module.Remove includes from a program.SSubstitute top-level includes with the declarations from the files they reference.PResolve the file referenced by a include into a list of top-level declarations.%Read a file referenced by an include.8(c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafe !"579:;M\Check for overlap and shadowingOnly check for overlapDon't check the environment+Multiple imported symbols contain this name.Expression name is not bound to any definition(Type name is not bound to any definition8An environment has produced multiple overlapping symbols[When a value is expected from the naming environment, but one or more types exist instead.eWhen a type is missing from the naming environment, but one or more values exist with the same name.)When the fixity of two operators conflict5When it's not possible to produce a Prop from a Type.6When a builtin type/type-function is used incorrectly.)When a builtin type is named in a binder.(Retrieve the name of the current module.;Shadow the current naming environment with some more names.Shadow the current naming environment with some more names. The boolean parameter indicates whether or not to check for shadowing.Generate warnings when the left environment shadows things defined in the right. Additionally, generate errors when two names overlap in the left environment.?Check the RHS of a single name rewrite for conflicting sources.AThrow errors for any names that overlap in a rewrite environment.Produce a name if one exists. Note that this includes situations where overlap exists, as it's just a query about anything being in scope. In the event that overlap does exist, an error will be recorded.vAssuming an error has been recorded already, construct a fake name that's not expected to make it out of the renamer.XRename a schema, assuming that the type variables have already been brought into scope.ACheck to see if this identifier is a reserved type/type-function.UWhen possible, rewrite the type operator to a known constructor, otherwise return a ; that reconstructs the original term, and a default fixity.1The name environment generated by a single match.ERename patterns, and collect the new environment that they introduce.Rename a binding./Resolve fixity, then rename the resulting type.PRename a schema, assuming that none of its type variables are already in scope.X     May contain infix expressionsThe operator to use"Will not contain infix expressions !"#()-./<>/<()-.>>       !"#9(c) 2015-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafe!"\oWhen given an equality constraint, attempt to rewrite it to the form `?x = ...`, by moving all occurrences of `?x` to the LHS, and any other variables to the RHS. This will only work when there's only one unification variable present in the prop.$RRank a rewrite, favoring expressions that have fewer subtractions than additions.%Rewrite an equation with respect to a unification variable ?x, into the form `?x = t`. There are two interesting cases to consider (four with symmetry):?x = tyexpr containing ?x = exprIn the first case, we just return the type variable and the type, but in the second we try to rewrite the equation until it's in the form of the first case.&6Check that a type contains only finite type variables.'*Rewrite an equality until the LHS is just uvar. Return the rewritten RHS.>There are a few interesting cases when rewriting the equality:A o B = R when uvar( is only present in A A o B = R when uvar is only present in B|In the first case, as we only consider addition and subtraction, the rewriting will continue on the left, after moving the BZ side to the RHS of the equation. In the second case, if the operation is addition, the A> side will be moved to the RHS, with rewriting continuing in B,. However, in the case of subtraction, the BG side is moved to the RHS, and rewriting continues on the RHS instead.In both cases, if the operation is addition, rewriting will only continue if the operand being moved to the RHS is known to be finite. If this check was not done, we would end up violating the well-definedness condition for subtraction (for a, b: well defined (a - b) iff fin b).$%&'$%&':(c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafe!"MAdd additional constraints that ensure validity of type function. Note that these constraints do not introduce additional malformed types, so the well-formedness constraints are guaranteed to be well-formed. This assumes that the parameters are well-formed. >Add additional constraints that ensure the validity of a type.(Import an improving substitutin (i.e., a bunch of equations) into a Cryptol substitution (which is idempotent). The substitution will contain only unification variables.  Improvements3 on skolem variables become additional constraints.)Import an improving substitution into a Cryptol substitution. The substitution will contain both unification and skolem variables, so this should be used when processing *givens*.Try to pick a reasonable instantiation for an expression, with the given type. This is useful when we do evaluation at the REPL. The resulting types should satisfy the constraints of the schema.*iAttempt to default the given constraints by asserting them in the SMT solver, and asking it for a model.+Checking this function?These appear in the env., and we should not try to default theType parametersAssumed constraintCollected constraints,-.Left: contradiciting goals, Right: goals that were not solved, or sub-goals for solved goals. Does not include "old"/Consult these  Solve these 01()2*34+,-./01()2*34;(c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafe JApply a testable value to some randomly-generated arguments. Returns  : if the function returned  R/, or `Just counterexample` if it returned  S.oPlease note that this function assumes that the generators match the supplied value, otherwise we'll panic.Given a (function) type, compute generators for the function's arguments. Currently we do not support polymorphic functions. In principle, we could apply these to random types, and test the results. {A generator for values of the given type. This fails if we are given a type that lacks a suitable random value generator. Generate a random bit value.BGenerate a random word of the given length (i.e., a value of type [w]m) The size parameter is assumed to vary between 1 and 100, and we use it to generate smaller numbers first.(Generate a random infinite stream value.Generate a random sequence. Generally, this should be used for sequences other than bits. For sequences of bits use "randomWord". The difference is mostly about how the results will be displayed. Generate a random tuple value.Generate a random record value. Function under testArgument generatorsSize   <(c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportable Trustworthy!"$LMOT Make a numeric constant.Create a packed wordKTurn a normal binop on Integers into one that can also deal with a bitsize. %Lexicographic ordering on two values.;Process two elements based on their lexicographic ordering.4Join a sequence of sequences into a single sequence.Split implementation.!Split into infinitely many chunksSplit into finitely many chunksBMerge two values given a binop. This is used for and, or and xor.%,Indexing operations that return one element.(.Indexing operations that return many elements..Produce a random value with the given seed. If we do not support making values of the given type, return zero of that type. TODO: do better than returning zero6bit size of the resulting wordbaseexponentbase exponent maskmodulus     fThe function may assume its arguments are masked. It is responsible for masking its result if needed. !"#$%&'()*+,-.6      !"#$%&'()*+,-.6      !"#$%&'()*+,-.6      !"#$%&'()*+,-.=(c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafeM5Evaluation environments for list comprehensions: Each variable name is bound to a list of values, one for each element in the list comprehension.6A variation of the ZipList type from Control.Applicative, with a separate constructor for pure values. This datatype is used to represent the list of values that each variable takes on within a list comprehension. The Ziph constructor is for bindings that take different values at different positions in the list, while the Pure{ constructor is for bindings originating outside the list comprehension, which have the same value for all list positions.71Introduce the constructor function for a newtype.8Take parallel slices of the list environment. If some names are bound to longer lists of values (e.g. if they come from a different parallel branch of a comprehension) then the last elements will be dropped as the lists are zipped together.9Evaluate a comprehension.:UTurn a list of matches into the final environments for each iteration of the branch.;9Turn a match into the list of environments it represents.5<=>6?@/0A71BCDEF8G9:;234 #&($%'56/01 /01#$%&'(565<=>6?@/0A71BCDEF8G9:;234>(c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableNone!"$:M FXMake a numeric constant. { val, bits } (fin val, fin bits, bits >= width val) => [bits]G7Models functions of type `{a} (Arith a) => a -> a -> a`H2Models functions of type `{a} (Arith a) => a -> a`JCeiling (log_2 x)U4Join a sequence of sequences into a single sequence.VSplit implementation.W!Split into infinitely many chunksXSplit into finitely many chunksYBMerge two values given a binop. This is used for and, or and xor.^Add two polynomials/56789:;<=>?number of elementstype of elementelement@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abc/56789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abc/789:;<=>?@ABCDEF65GHIJKLMNOPQRSTUVWXYZ[\]^_`abc/56789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abc?(c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafeJ dCheck a type signature.e!Check a type-synonym declaration.fACheck a newtype declaration. XXX: Do something with constraints.H%Check something with type parameters.When we check things with type parameters (i.e., type schemas, and type synonym declarations) we do kind inference based only on the immediately visible body. Type parameters that are not mentioned in the body are defaulted to kind mm. If this is not the desired behavior, programmers may add explicit kind annotations on the type parameters.+Here is an example of how this may show up: !f : {n}. [8] -> [8] f x = x + `n Note that nE does not appear in the body of the schema, so we will default it to mu, which is the correct thing in this case. To use such a function, we'd have to provide an explicit type application:  f `{n = 3}&There are two reasons for this choice: uIt makes it possible to figure if something is correct without having to look through arbitrary amounts of code.It is a bit easier to implement, and it covers the large majority of use cases, with a very small inconvenience (an explicit kind annotation) in the rest.I(Check an application of a type constant.J@Check a use of a type-synonym, newtype, or scoped-type variable.KCheck a type-application.LValidate a parsed type.M&Check a type-variable or type-synonym.NValidate a parsed proposition.O(Check that a type has the expected kind. defgHIType constant being appliedType parameters Expected kindResulting typeJ%Should we check for scoped type vars.Name of type sysnonymType synonym parameters Expected kindResulting typeKParameters to type functionKind of type function$Validated parameters, resulting kindLType that needs to be checkedExpected kind (if any) Checked typeM!Name of thing that needs checking Expected kindN#Proposition that need to be checkedChecked representationOKind-checked typeExpected kind (if any) Inferred kind$A type consistent with expectations.defggdfe defgHIJKLMNO@(c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafe!"$JM i(Construct a primitive in the parsed AST.k?Infer the type of an expression with an explicit instantiation.n]We use this when we want to ensure that the expr has exactly (syntactically) the given type.oSInfer the type of an expression, and translate it to a fully elaborated core term.w$The type the is the smallest of all yPInfer the type of a pattern. Assumes that the pattern will be just a variable. z4Infer the type of one match in a list comprehension.{2Infer the type of one arm of a list comprehension.|!inferBinds isTopLevel isRec binds; performs inference for a strongly-connected component of s. If  isTopLevel is true, any bindings without type signatures will be generalized. If it is false, and the mono-binds flag is enabled, no bindings without type signatures will be generalized, but bindings with signatures will be unaffected.}Come up with a type for recursive calls to a function, and decide how we are going to be checking the binding. Returns: (Name, type or schema, computation to check binding)The exprMapd is a thunk where we can lookup the final expressions and we should be careful not to force it.~/Try to evaluate the inferred type in a binding._The inputs should be declarations with monomorphic types (i.e., of the form `Forall [] [] t`).hijklmnopqrstuvwxyz{|}~hijklmnopqrstuvwxyz{|}~hijklmnopqrstuvwxyz{|}~hijklmnopqrstuvwxyz{|}~A(c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafeM6dfqneghijklmoprstuvwxyz{|}~ !%&'()*+,-./06%&'()*+,-./ !0defghijklmnopqrstuvwxyz{|}~B(c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafe!"57M Extra information we need to carry around to dynamically extend an environment outside the context of a single module. Particularly useful when dealing with interactive declarations as in :let or it..Invariant: All the dependencies of any module m must precede m in the list.Don't run core lint Run core lint7Try to focus a loaded module in the module environment.wGet a list of all the loaded modules. Each module in the resulting list depends only on other modules that precede it.bProduce an ifaceDecls that represents the focused environment of the module system, as well as a c5 for pretty-printing names according to the imports.XXX This could really do with some better error handling, just returning mempty when one of the imports fails isn't really desirable.OThe unqualified declarations and name environment for the dynamic environment. Retrieve all e referenced by a module, as well as all of its public and private declarations, checking expressionsBuild D that correspond to all of the bindings in the dynamic environment.IXXX: if we ever add type synonyms or newtypes at the REPL, revisit this.+)+ C(c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableSafe57:=Unable to find the module given, tried looking in these pathsUnable to open a file4Some other IO error occurred while reading this file=Generated this parse error when parsing the file for module m!Recursive module group discovered"Problems during the renaming phaseProblems during the NoPat phase#Problems during the NoInclude phaseProblems during type checking0Problems after type checking, eg. specializationModule loaded by 'import'$ statement has the wrong module nameATwo modules loaded from different files have the same module namegPush an "interactive" context onto the loading stack. A bit of a hack, as it uses a faked module name(Get the currently focused import source.;Remove a module from the set of loaded module, by its path. Run a  action in a context with a prepended search path. Useful for temporarily looking in other places while resolving imports, for example.U               K         U                 A                N(c) 2015-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableNoneP[Write the contents of the Prelude to a temporary file so that Cryptol can load the module.QPPQPD(c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableNone!": &7Rename a module in the context of its imported modules. 'Run the noPat pass. )Load a module by its path. *'Load the module specified by an import. +>Load dependencies, typecheck, and add to the eval environment. ,0Rewrite an import declaration to be of the form: &import foo as foo [ [hiding] (a,b,c) ] -cFind the interface referenced by an import, and generate the naming environment that it describes. .=Load a series of interfaces, merging their public interfaces. 0Discover a module. 1'Discover a file. This is distinct from  0D in that we assume we've already been given a particular file name. 2AAdd the prelude to the import list if it's not already mentioned. 37Load the dependencies of a module into the environment. 4Load the local environment, which consists of the environment for the currently opened module, shadowed by the dynamic environment. 5uTypecheck a single expression, yielding a renamed parsed expression, typechecked core expression, and a type schema. 6"Typecheck a group of declarations.LINVARIANT: This assumes that NoPat has already been run on the declarations. 7Generate the primitive map. If the prelude is currently being loaded, this should be generated directly from the naming environment given to the renamer instead. 8Typecheck a module. =#Generate input for the typechecker.$     ! " # $ % & ' ( ) * + , - . / 0 1 2 3 4 5 6 7 8 9 : ; < = > ?$     ! " # $ % & ' ( ) * + , - . / 0 1 2 3 4 5 6 7 8 9 : ; < = > ?$ % & ' ( ) * + , - . / 0 1 2 3 4 5 6 7 8 ! " # $ 9 : ;     < = > ?     ! " # $ % & ' ( ) * + , - . / 0 1 2 3 4 5 6 7 8 9 : ; < = > ?E(c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableNone: CFFind the file associated with a module name in the module search path. D,Load the module contained in the given file. ELoad the given parsed module. FnCheck the type of an expression. Give back the renamed expression, the core expression, and its type schema. GEvaluate an expression. H!Typecheck top-level declarations. I?Evaluate declarations and add them to the extended environment. @ A B C D E F G H I J K LD @ A B C D E F G H I J K LD A @ C D E F G H I J B K L @ A B C D E F G H I J K LF(c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableNone NThe specializer monad. OsA Name should have an entry in the SpecCache iff it is specializable. Each Name starts out with an empty TypesMap. VAdd a `where` clause to the given expression containing type-specialized versions of all functions called (transitively) by the body of the expression. YAdd the declarations to the SpecCache, run the given monadic action, and then pull the specialized declarations back out of the SpecCache state. Return the result along with the declarations and a table of names of specialized bindings. Z<Compute the specialization of `EWhere e dgs`. A decl within dgse is replicated once for each monomorphic type instance at which it is used; decls not mentioned in e- (even monomorphic ones) are simply dropped. [qTransform the given declaration groups into a set of monomorphic declarations. All of the original declarations with monomorphic types are kept; additionally the result set includes instantiated versions of polymorphic decls that are referenced by the monomorphic bindings. We also return a map relating generated names to the names from the original declarations. a)Freshen a name by giving it a new unique. c3Reduce `length ts` outermost type abstractions and n proof abstractions. M N O P Q R S T U V W X Y Z [ \ ] ^ _ ` a b c d e f g M N O P Q R S T U V W X Y Z [ \ ] ^ _ ` a b c d e f g O N M P Q R S T U V W X Y Z [ \ ] ^ _ ` a b c d e f g M N O P Q R S T U V W X Y Z [ \ ] ^ _ ` a b c d e f gG(c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableNone!"$:LMT qA prover result is either an error message, an empty result (eg for the offline prover), a counterexample or a lazy list of satisfying assignments. xThe type of query to run y+Which prover to use (one of the strings in  ) zVerbosity flag passed to SBV {?Extra declarations to bring into scope for symbolic simulation |,Optionally output the SMTLIB query to a file }&The typechecked expression to evaluate ~The f of pcExpr .Bind a variable in the evaluation environment. %Lookup a variable in the environment. Bind a type variable of kind *. Lookup a type variable. Make a copy of the given value, building the spine based only on the type without forcing the value argument. This lets us avoid strictness problems when evaluating recursive definitions. Evaluate a comprehension. UTurn a list of matches into the final environments for each iteration of the branch. 9Turn a match into the list of environments it represents.B h i j k l m n o p q r s t u v w x y z { | } ~  A h i j k l m n o p q r s t u v w x y z { | } ~  B  v w x y z { | } ~ q r s t u l m n o p h i j k + h i j k l m n o p q r s t u v w x y z { | } ~   H(c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableNone !"$0<=DMR[R:User modifiable environment, for things like numeric base. REPL exceptions. #REPL_ context with InputT handling.SREPL RW Environment. Focused module  Focused fileTInitial, empty environment.U!Build up the prompt for the REPL. +Run a REPL action with a fresh environment. Raise an exception. 1Construct the prompt for the current environment. 6Set the name of the currently focused file, edited by :e and loaded via :r. PRun a computation in batch mode, restoring the previous isBatch flag afterwards &Are let-bindings enabled in this REPL? Update the title <Set the function that will be called when updating the title Set the REPL's string-printer Get the REPL's string-printer 2Use the configured output action to print a string JUse the configured output action to print a string with a trailing newline KUse the configured output action to print something using its Show instance Get visible variable names. !Get visible type signature names. @Return a list of property names, sorted by position in the file. Given an existing qualified name, prefix it with a relatively-unique string. We make it unique by prefixing with a character #. that is not lexically valid in a module name. OGenerate a fresh name using the given index. The name will reside within the " interactive " namespace.V9Generate a UserEnv from a description of the options map. Set a user option. +Get a user option, using Maybe for failure. OGet a user option, when it's known to exist. Fail with panic when it doesn't.WCheck the value to the base option.q X Y R SZ[\]^_`ab TU cde V f gh Wijkl m K K O  X  Y  R  S Z[\]^_`ab  TU cde V f gh Wijkl m I(c) 2013-2016 Galois, Inc.BSD3cryptol@galois.com provisionalportableNone!":M Command builder.  Commands. Successfully parsed command 2Ambiguous command, list of conflicting commands The unknown commandnREPL command parsing.oNotebook command parsing.p0A subset of commands safe for Notebook execution Run a command. wRandomly test a property, or exhaustively check it if the number of values in the type under test is smaller than the tests9 environment variable, or we specify exhaustive testing.qConsole-specific version of proveSat/. Prints output to the console, and binds the its variable to a record whose form depends on the expression given. See ticket #66 for a discussion of this design.r<Make a type/expression pair that is suitable for binding to it after running :sat or :prove %*Lift a parsing action into the REPL monad.s@Check declarations as though they were defined at the top-level.thCreates a fresh binding of "it" to the expression given, and adds it to the current dynamic environmentuCreates a fresh binding of "it" to a finite sequence of expressions of the same type, and adds that sequence to the current dynamic environment ,Strip leading space.vStrip trailing space. -!Split at the first word boundary.wUncons a list. .$Lookup a string in the command list. /jLookup a string in the command list, returning an exact match even if it's the prefix of another command. 02Lookup a string in the notebook-safe command list. 1Parse a line as a command.Xx                nopyz {|   q  }r~ ! " # $ % & ' ( ) *s +tu ,v -w . / 0 1 2 3 4-                       ! " # $ % & ' ( ) * + , - . / 0 1-              1  - . / 0 " ! # ' & + *         $ , % ( )Gx                nopyz {|   q  }r~ ! " # $ % & ' ( ) *s +tu ,v -w . / 0 1 2 3 4OPKQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~                                                  LLLLLLLLL L!L"L#L$L%L&L'L(L)L*L+L,L-L.L/L0L1L2L3L4L5L6L7L8L9L:L;L<L=L>L?L@LALBLCLDLELFLGLHLILJLKLLLMLNLOLPLQLRLSLTLULVLWLXLYLZL[L\L]L^L_L`LaLbLcLdLeLfLgLhLiLjLkLlLlLmLnLoLoLpLqLqLrLsLtLuLvLw x y z { | } } ~             !"#$%&&'()*+,-./001234456789:;<=>?@8ABCCDEFGGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~       !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFG#$88HIJKLMNOPQRSTUVWXYZ[[\]^_`abcdefghijkl\dmnopqlnrstuvw00xyz{|}~CCDEF}orkunlm        !"#$%&'()*+,,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[!\]^_`abcde fghijklmnopqrstuvwxyz{|}~     <76= !"#$%&'()*+,-./0123456789 : ; P < = > ? @!A!A!B!C!D!E!F!G!H!I!J!K!L!M!N!O!P!Q!R!S!T!U!V!W!X!Y!Z![!\!]!^!_!`!a!b"c"d#e#f#g#h$i$j$k$l$m$n$o%p%p%q%r%s%t%u%u%v%w%x%y%z%{%|%}%~%%%%%%%%%&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&''(((((((((((S((())))******x********************++++++++++++++++++++,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,, , , , - --------------------- -!-"-#--$-%--&-'-(-)-*-+-,---.-/-0-1-2-3-4-4-5-6-7-7-8-9-:-;-<-<-=->-?-?-@-A-B-C-C-D-E-F-G-G-H-I-J-K-L-M-N-T-O-P-Q---R----S-T-U-V-W-X-Y-Z-[-\-]-^-_-`-a-b-c-d-e-f-g-h-i-j-k-l-m-n-o-p-q-r----s-t.u.v/w/x0y0z0{0|0}0~0~00000000000000000000000000111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111 1 1 1 1 1111111111111122222 2!2"2#2$2%2&2'2(2)2*3+4,5-5.M/M0M1M2636465666768696:6;6<6=6>6?6@6A6B6C7D7E7F7G7H7I7J7K7L7M7N7O8P8Q8R8S8T8U8V8W8X8Y8Z8[8\8]8^8_8`8a8b8c8d8e8f8g8h8i8j8k8l8m8n8o8p8q8r8s8t8u8v8w8x8y8z8{8|8}8~88889::::::::;;;;;;;;;;<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<======>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>????@@@@@@@@@@@@@@@@@@@@@@@@ @ @ @ @ AAAAA2BBBBBBBBBBBBBBBBBBBBBB B!B"B#B$B%B&B'B(B)B*B+B,B-B.B/B0B1B2B3B4B5B6B7B8B9B:B;B<B=B>B?B@BACBCCCCCDCCCECFCGCHCICJCKCLCMCNCOCPCQCRCSCTCUCVCWCXCYCZC[C\C]C^C_C`CaCbCcCdCeCfCgChCiCjCCkClCmC/CnCoCpCqCrCsCtCuCCvCwCxCyCzC{C|C}C~CCCCCCCCCCCCCCCCCCCCCCCCCDDDDDDDDDDQDcDD6DDDDDDDDDDDDDDDDDDDDDDDEEEEEEEEEEEEdEeFFFFFFFFFFFFFFFFFFFFFFFFFFFGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGGG 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 HH H H H H H HHH H H H !H "H #HH $H %H &H 'H (H )H *H +H ,H -H .H /H 0H 1H 2H 3H 4H 5H 6HH 7HHH 8H 9H :HkHlHHH ;HH <H =H >H ?H @H AH BH CH DH EH FH GH HH IH JH KH LH MH NH OH PI QI RI SI TI UI VI WI XI YI ZI [I \I ]I ]I ^I _I `I aI aI bI cI dI eI fI gI hI iI jI kI lI mI nI oI pI qI rI sI tI uI vI wI xI yI zI {I |I }I ~I I J J J  K K K K K K K K K K K K             L L L L L L L L L L LL LL 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 LL L L L L L L L L L L L L                                          ! " # $ % & ' ( ) * + , - . / 0 1 2 3 4 5 6 7 8 9 : ; < = > ? @ A B C D E F G H I J K L M N O P Q R R S T U V W X Y Z [ \ ] ^ _ ` a b c d e f g h i j k l m n o p m n q r s t u v w x y z { | } ~           m  m     w        E    3      `           " $ $ $ $ $ $ $ $ $ $ & '' '' ' ' ' ' ' ' ' ' ' ' ' ' ++ + + + + + + + + +++++ c+ + + + + + + + + + + + + + + + + + + + + ++ . . . . 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0|0 0 0 0 0 0 0 0 0 0 0 0 0  m  3 3 3 4 4 4 4 4 M M M MMM M M M M M M !M "M #M $M %M &M 'M (M )M *M +M ,M -M .M /M 0M 1M 2M 3M 4M 5M 6M 7M 8M 9M :M ;M <M {M =M >M ?M @M AM BM CM D6 E6 F6 G6 G6 H6 I6 J6 K6 K6 L6 M6 N6 O6 P6 Q6 R6 S6 T6 U6 V6 W6 X6 Y6 Z6 [6 \6 ]6 ^6 _6 `6 a6 b6 c6 d6 e6 f6 g6 h6 i6 j6 k6 l6 m6 n6 o6 p6 q6 r6 s6 t6 u6 v6 w6 x6 y6 z6 {6 |6 }6 ~6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 !6 "6 #6 $6 %6 &6 '6 (6 )6 *6 +6 ,6 -6 .6 /6 06 16 26 36 46 56 66 76 86 96 :6 ;6 <6 =6 >6 ?6 @6 A6 B6 C6 D6 E6 F6 G6 H6 I6 J6 K6 L6 M6 N6 O6 P6 Q6 R6 S6 T6 U6 V6 W6 X6 Y6 Z6 [6 \6 ]6 ^6 _6 `6 a6 b6 c6 d6 e6 f6 g6 h6 i6 j6 k6 l6 m6 n6 o6 p6 q6 r6 s6 t6 u6 v6 w6 x6 y6 z6 {6 |6 }6 ~6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 !6 "6 #6 $6 %6 &6 '6 (6 )6 *6 +6 ,6 -6 .6 /6 06 16 26 36 46 56 66 76 86 96 :6 ;6 <6 =6 >6 ?6 @6 A6 B6 C6 D6 E6 F6 G6 H6 I6 J6 K6 L6 M6 N6 O6 P6 Q6 R6 S6 T6 U6 V6 W6 X6 Y6 Z6 [6 \6 ]6 ^6 _6 `6 a6 b6 c6 d6 e6 f6 g6 h6 i6 j6 k6 l6 m6 n6 o6 p6 q6 r6 s6 t6 u6 v6 w6 x6 y6 z6 {6 |6 }6 ~6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6667777777 7 7 7  77777777 7 7788888888888 8!8"8#8$8%8R8&888'8(8)888*8+8,8-8.8/808182838485868788898:8;8<8=9>9?9@9A:B:C:D:E:F:G:H:I:J:K:L: :M=N=O=P=Q= = = =N=R=S=T=U=V====W=X=Y??j?Z?[?\?]?^?_N`NaHbHHcHdHeHfHgHhHHiHjHkHlHmHnHoHpHqHrHsHtHuHvHwHxHyHzH{I|I}I~IIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIII$cryptol-2.4.0-AtabUoGsZJn8kSvO8P84NPCryptol.Utils.MiscCryptol.VersionCryptol.Utils.PanicCryptol.Parser.UnlitCryptol.REPL.TrieCryptol.Eval.ArchCryptol.TypeCheck.Solver.InfNatCryptol.Utils.IdentCryptol.Utils.PPCryptol.Parser.PositionCryptol.Parser.LexerCryptol.Utils.DebugCryptol.TypeCheck.PPCryptol.Parser.NameCryptol.Prims.SyntaxCryptol.Parser.ASTCryptol.ModuleSystem.NameCryptol.TypeCheck.ASTCryptol.Eval.ErrorCryptol.Eval.ValueCryptol.Symbolic.ValueCryptol.TypeCheck.TypeMapCryptol.TypeCheck.SubstCryptol.TypeCheck.SanityCryptol.TypeCheck.Unify$Cryptol.TypeCheck.Solver.Numeric.AST-Cryptol.TypeCheck.Solver.Numeric.SimplifyExpr*Cryptol.TypeCheck.Solver.Numeric.Simplify1(Cryptol.TypeCheck.Solver.Numeric.Defined)Cryptol.TypeCheck.Solver.Numeric.Simplify'Cryptol.TypeCheck.Solver.Numeric.NonLin-Cryptol.TypeCheck.Solver.Numeric.ImportExport)Cryptol.TypeCheck.Solver.Numeric.IntervalCryptol.TypeCheck.TypeOfCryptol.TypeCheck.Solver.Utils$Cryptol.TypeCheck.Solver.Numeric.SMTCryptol.Testing.ConcreteCryptol.ModuleSystem.InterfaceCryptol.Transform.MonoValuesCryptol.Eval.EnvCryptol.Eval.TypeCryptol.Parser.NamesCryptol.Parser.NoPatCryptol.ModuleSystem.NamingEnvCryptol.TypeCheck.InferTypesCryptol.TypeCheck.Solver.Class$Cryptol.TypeCheck.Solver.Numeric.FinCryptol.TypeCheck.Solver.CrySATCryptol.TypeCheck.MonadCryptol.TypeCheck.DependsCryptol.TypeCheck.Instantiate!Cryptol.TypeCheck.Solver.SelectorCryptol.Parser.UtilsCryptol.ParserCryptol.Parser.NoIncludeCryptol.ModuleSystem.Renamer!Cryptol.TypeCheck.Solver.SimplifyCryptol.TypeCheck.SolveCryptol.Testing.RandomCryptol.Prims.Eval Cryptol.EvalCryptol.Symbolic.PrimsCryptol.TypeCheck.KindCryptol.TypeCheck.InferCryptol.TypeCheckCryptol.ModuleSystem.EnvCryptol.ModuleSystem.MonadCryptol.ModuleSystem.BaseCryptol.ModuleSystemCryptol.Transform.SpecializeCryptol.SymbolicCryptol.REPL.MonadCryptol.REPL.CommandGitRev Paths_cryptolCryptol.Parser.LexerUtilsCryptol.Parser.ParserUtilsCryptol.PreludeanyJustanyJust2version commitHashcommitShortHash commitBranch commitDirtypanic$fExceptionCryptolPanic$fShowCryptolPanicPreProcNoneMarkdownLaTeX knownExts guessPreProcunLitTrieNode emptyTrie insertTrie lookupTrielookupTrieExactleaves $fShowTriemaxBigIntWidthNat'NatInffromNatnEqnGtnFinnAddnMulnExpnMinnMaxnSubnDivnModnLg2nWidth nLenFromThennLenFromThenTogenLog widthInteger rootExactgenRoot $fShowNat'$fEqNat' $fOrdNat' $fGenericNat' $fNFDataNat'IdentModName unpackModName packModNamemodSep packIdent packInfix unpackIdentmkIdentmkInfix isInfixIdent nullIdent identText preludeNameinteractiveName $fNFDataIdent$fIsStringIdent $fOrdIdent $fEqIdent $fShowIdent$fGenericIdentInfixieOpieLeftieRightiePrecieAssocAssoc LeftAssoc RightAssocNonAssocPPName ppNameFixity ppPrefixName ppInfixNamePPppPrecDoc NameFormat UnQualified Qualified NotInScopeNameDisp EmptyNameDispneverQualifyMod alwaysQualify neverQualify fmtModNameextend getNameFormat withNameDisp fixNameDisprunDocrenderpppretty optParenscommaSepppInfixordinal ordSuffixliftPJliftPJ1liftPJ2liftSep<><+>$$sepfsephsephcatvcathangnestparensbracesbracketsquotes punctuatetextcharintegerintcommaemptycolon $fPPIdent$fPPText $fIsStringDoc $fShowDoc $fMonoidDoc$fMonoidNameDisp$fShowNameDisp$fShowNameFormat$fGenericNameDisp$fNFDataNameDisp $fGenericDoc $fNFDataDoc $fShowAssoc $fEqAssoc$fGenericAssoc $fNFDataAssocAddLocaddLocdropLocHasLocgetLocRangefromtosourcePositionlinecolLocatedsrcRangething emptyRangestartmovemovesrCombrCombsat$fAddLocLocated $fHasLoc[] $fHasLoc(,)$fHasLocLocated $fHasLocRange$fPPNameLocated $fPPLocated $fPPRange $fPPPosition$fFunctorLocated $fEqPosition $fOrdPosition$fShowPosition$fGenericPosition$fNFDataPosition $fEqRange $fShowRange$fGenericRange $fNFDataRange $fEqLocated $fShowLocated$fGenericLocated$fNFDataLocatedTokenTNumChrLitStrLitKWOpSymVirtWhiteErrEOFTokenErrUnterminatedCommentUnterminatedStringUnterminatedChar InvalidString InvalidChar LexicalErrorTokenSymBarArrLArrRFatArrRLambdaEqDefCommaSemiDotDotDot DotDotDotColonBackTickParenLParenRBracketLBracketRCurlyLCurlyRTriLTriR UnderscoreTokenKWKW_ArithKW_BitKW_CmpKW_elseKW_Eq KW_externKW_finKW_if KW_private KW_includeKW_infKW_lg2KW_lengthFromThenKW_lengthFromThenToKW_maxKW_min KW_module KW_newtype KW_pragma KW_propertyKW_thenKW_typeKW_whereKW_letKW_x KW_importKW_as KW_hiding KW_infixl KW_infixrKW_infix KW_primitiveTokenW BlockComment LineCommentSpaceDocStrTokenVVCurlyLVCurlyRVSemiToken tokenType tokenTextLayoutNoLayoutConfig cfgSource cfgLayout cfgPreProccfgAutoIncludecfgModuleScope defaultConfiglexer primLexer$fFunctorAlexLastAcctraceppTrace WithNamesNameMap emptyNameMapppWithNamesPrec ppWithNamesdumpnameList intToNamePassNoPat MonoValuesPNameUnQualQualNewNamemkUnqualmkQual getModNamegetIdent $fPPNamePName $fPPPName $fNFDataPass $fNFDataPName$fEqPass $fOrdPass $fShowPass $fGenericPass $fEqPName $fOrdPName $fShowPName$fGenericPNameTFunTCAddTCSubTCMulTCDivTCModTCExpTCWidthTCMinTCMax TCLenFromThenTCLenFromThenTo tBinOpPrec tfunNames$fPPTFun $fPPNameTFun $fShowTFun$fEqTFun $fOrdTFun $fBoundedTFun $fEnumTFun $fGenericTFun $fNFDataTFunNoPosnoPosPropCFinCEqualCGeqCArithCCmpCLocatedCTypeTypeTSeqTBitTNumTCharTInfTUserTAppTRecordTTupleTWildTLocatedTParensTInfixTParamtpNametpKindtpRangeKindKNumKTypeSchemaForallNamednamevaluePatternPVarPWildPTuplePRecordPListPTypedPSplitPLocatedMatchMatchLetSelectorTupleSel RecordSelListSelTypeInst NamedInstPosInstExprEVarELitETupleERecordESelEListEFromToEInfFromECompEAppEAppTEIfEWhereETypedETypeValEFunELocatedEParensEInfixLiteralECNumECStringNumInfoBinLitOctLitDecLitHexLitCharLitPolyLit ExportSpeceTypeseBindsTopLeveltlExporttlDoctlValue ExportTypePublicPrivate ReplInput ExprInputLetInputNewtypenNamenParamsnBodyPragma PragmaNotePragmaProperty FixityCmpFCErrorFCLeftFCRightFixityfAssocfLevelBindDefDPrimDExprLBindDefBindbNamebParamsbDef bSignaturebInfixbFixitybPragmasbMonobDocTySyn ImportSpecHidingOnlyImportiModuleiAsiSpecDecl DSignatureDFixityDPragmaDBindDPatBindDTypeDLocatedTopDecl TDNewtypeIncludeModulemNamemImportsmDeclsProgramLStringLIdentLPNamemodRange compareFixity defaultFixity exportBindisExportedBind exportTypeisExportedType tconNames ppSelectorcppKind $fNoPosProp $fNoPosType $fNoPosTParam $fNoPosSchema$fNoPosPattern $fNoPosMatch$fNoPosTypeInst $fNoPosExpr $fNoPosTySyn $fNoPosPragma $fNoPosBind$fNoPosNewtype $fNoPosDecl$fNoPosTopLevel$fNoPosTopDecl $fNoPosModule$fNoPosProgram $fNoPosMaybe $fNoPos[] $fNoPosNamed$fNoPosLocated$fPPProp$fPPType $fPPTParam$fPPKind $fPPSchema $fPPMatch $fPPPattern $fPPSelector$fPPExpr $fPPTypeInst $fPPLiteral $fPPTySyn $fPPBindDef$fPPBind $fPPPragma $fPPTopLevel$fPPImportSpec $fPPImport $fPPNewtype$fPPDecl $fPPTopDecl $fPPProgram $fPPModule$fHasLocNewtype$fHasLocModule$fHasLocTopDecl$fHasLocTopLevel $fAddLocDecl $fHasLocDecl$fAddLocSchema$fHasLocSchema $fHasLocNamed $fHasLocMatch $fHasLocBind$fHasLocPattern$fAddLocPattern $fAddLocProp $fHasLocProp $fAddLocType $fHasLocType$fAddLocTParam$fHasLocTParam $fHasLocExpr $fAddLocExpr$fMonoidExportSpec$fEqImportSpec$fShowImportSpec$fGenericImportSpec$fNFDataImportSpec $fEqImport $fShowImport$fGenericImport$fNFDataImport $fEqFixity $fShowFixity$fGenericFixity$fNFDataFixity$fShowFixityCmp $fEqFixityCmp $fEqPragma $fShowPragma$fGenericPragma$fNFDataPragma$fEqExportType$fShowExportType$fOrdExportType$fGenericExportType$fNFDataExportType$fShowTopLevel$fGenericTopLevel$fNFDataTopLevel$fFunctorTopLevel$fFoldableTopLevel$fTraversableTopLevel$fShowExportSpec$fGenericExportSpec$fNFDataExportSpec $fEqNumInfo $fShowNumInfo$fGenericNumInfo$fNFDataNumInfo $fEqLiteral $fShowLiteral$fGenericLiteral$fNFDataLiteral $fEqSelector$fShowSelector $fOrdSelector$fGenericSelector$fNFDataSelector $fEqNamed $fShowNamed$fFoldableNamed$fTraversableNamed$fGenericNamed $fNFDataNamed$fFunctorNamed$fEqKind $fShowKind $fGenericKind $fNFDataKind $fEqTParam $fShowTParam$fGenericTParam$fNFDataTParam$fEqType $fShowType $fGenericType $fNFDataType $fEqPattern $fShowPattern$fGenericPattern$fNFDataPattern $fEqTypeInst$fShowTypeInst$fGenericTypeInst$fNFDataTypeInst $fEqNewtype $fShowNewtype$fGenericNewtype$fNFDataNewtype $fEqTySyn $fShowTySyn$fGenericTySyn $fNFDataTySyn$fEqProp $fShowProp $fGenericProp $fNFDataProp $fEqSchema $fShowSchema$fGenericSchema$fNFDataSchema$fEqDecl $fShowDecl $fGenericDecl $fNFDataDecl$fEqExpr $fShowExpr $fGenericExpr $fNFDataExpr $fEqMatch $fShowMatch$fGenericMatch $fNFDataMatch$fEqBind $fShowBind $fGenericBind $fNFDataBind $fEqBindDef $fShowBindDef$fGenericBindDef$fNFDataBindDef $fEqReplInput$fShowReplInput $fShowTopDecl$fGenericTopDecl$fNFDataTopDecl $fShowModule$fGenericModule$fNFDataModule $fShowProgramPrimMap primDecls primTypesSupplySupplyTFreshM liftSupplyNameNameInfoDeclared ParametercmpNameLexicalcmpNameDisplay ppLocName nameUnique nameIdentnameInfonameLoc nameFixityasPrim runSupplyT nextUniqueM emptySupply nextUnique mkDeclared mkParameterlookupPrimDecllookupPrimType$fMonadFixSupplyT$fRunMSupplyTa(->)$fBaseMSupplyTn$fMonadTSupplyT$fMonadSupplyT$fApplicativeSupplyT$fFunctorSupplyT$fFreshMSupplyT$fFreshMStateT$fFreshMReaderT$fFreshMWriterT$fFreshMExceptionT $fPPNameName$fPPName $fOrdName$fEqName $fEqNameInfo$fShowNameInfo$fGenericNameInfo$fNFDataNameInfo $fShowName $fGenericName $fNFDataName $fShowSupply$fGenericSupply$fNFDataSupply $fShowPrimMap$fGenericPrimMap$fNFDataPrimMapHasKindkindOfDeclDefdName dSignature dDefinitiondPragmasdInfixdFixitydDoc DeclGroup Recursive NonRecursiveFromLetERecETAbsETAppEAbs EProofAbs EProofAppECastUserTCTCTCNumTCInfTCBitTCSeqTCFunTCTuple TCNewtypePCPEqualPNeqPGeqPFinPHasPArithPCmpTConTFTVarTVFreeTVBoundSTypeTRectpUniquentNamentParams ntConstraintsntFieldstsNametsParams tsConstraintstsDefsVarssPropssTypeKProp:->mExportsmTySyns mNewtypestpVar groupDeclsisFreeTV isBoundTVtIsNat'tIsNumtIsInftIsVartIsFuntIsSeqtIsBittIsTuple tIsBinFun tSplitFunpIsFinpIsGeqpIsEqpIsArithpIsCmp pIsNumerictNumtZerotOnetTwotInftNat'tBittWordtSeqtChartStringtRectTupletFuntNoUsertWidth tLenFromThentLenFromThenTotMax=#==/=pArithpCmp>==pHaspFin.*..+..-..^.tDivtModtMin newtypeTyConnewtypeConTypeePrimeErroreStringeChar quickApply addTNamesppNewtypeShortppLam splitWhilesplitAbs splitTAbs splitProofAbs $fPPWithNames$fPPWithNames0$fPPWithNames1 $fPPDeclGroup$fPPWithNames2$fPPWithNames3$fPPWithNames4 $fPPUserTC$fPPTC$fPPPC$fPPTCon$fPPWithNames5$fPPWithNames6$fPPWithNames7$fPPWithNames8$fPPTVar$fPPWithNames9$fHasKindTParam$fHasKindNewtype$fHasKindTySyn $fHasKindType $fHasKindTFun $fHasKindPC $fHasKindTC$fHasKindUserTC $fHasKindTCon $fHasKindTVar $fOrdTVar$fEqTVar $fOrdUserTC $fEqUserTC $fOrdTParam $fShowTVar $fGenericTVar $fNFDataTVar$fShowPC$fEqPC$fOrdPC $fGenericPC $fNFDataPC $fShowUserTC$fGenericUserTC$fNFDataUserTC$fShowTC$fEqTC$fOrdTC $fGenericTC $fNFDataTC $fShowTCon$fEqTCon $fOrdTCon $fGenericTCon $fNFDataTCon $fOrdType $fShowDeclDef$fGenericDeclDef$fNFDataDeclDef$fShowDeclGroup$fGenericDeclGroup$fNFDataDeclGroup EvalError InvalidIndexTypeCannotBeDemoted DivideByZero WordTooWide UserError evalPanic invalidIndextypeCannotBeDemoted divideByZero wordTooWide cryUserError$fExceptionEvalError $fPPEvalError$fShowEvalErrorBitWordpackWord unpackWordWithBasePPOptsuseAsciiuseBase useInfLengthTValueTVBitTVSeqTVStreamTVTupleTVRecTVFunValueGenValueVRecordVTupleVBitVSeqVWordVStreamVFunVPolyVNumPolyBVisTBitisTSeqisTFunisTTupleisTRectvSeqfinNat'mkBvtValTy defaultPPOptsppValue asciiMode integerToCharppWordmaskwordlamtlamnlamtoStreamtoFinSeq boolToWordtoSeq toPackedSeqfromVBitfromSeqfromStr fromVWordvWordLenfromWordfromVFun fromVPoly fromVNumPoly fromVTuple fromVRecord lookupRecordtoExpr$fBitWordBoolBV $fPPWithBase $fShowTValue $fGenericBV $fNFDataBV$fGenericTValue$fNFDataTValue$fGenericGenValue$fNFDataGenValue$fFunctorWithBaseSWordSBool fromBitsLE literalSWord forallBV_ existsBV_ forallSBool_ existsSBool_iteValue mergeValue$fBitWordSValSValTypeMapTMtvartcontrecTypesMapListLnilconsTrieMapemptyTMnullTMlookupTMalterTMunionTMtoListTMmapMaybeWithKeyTM membersTMinsertTM insertWithTMmapTM mapWithKeyTM mapMaybeTM $fShowTypeMap$fTrieMapTypeMapType $fTrieMapMapa$fTrieMapList[] $fFunctorList$fFunctorTypeMapTVarsapSubstFVSfvsSubstSsuMap suDefaulting emptySubst singleSubst@@defaultingSubst listSubst isEmptySubst substToList apSubstMaybedefaultFreeVarapSubstTypeMapKeys $fTVarsModule$fTVarsDeclDef $fTVarsDecl$fTVarsDeclGroup $fTVarsMatch $fTVarsExpr $fTVarsSchema$fTVarsTypeMap $fTVarsList $fTVarsType $fTVars(,) $fTVars[] $fTVarsMaybe $fFVSSchema$fFVS(,)$fFVS[] $fFVSType $fPPSubst $fShowSubstError TypeMismatch ExpectedMonoTupleSelectorOutOfRange MissingFieldUnexpectedTupleShapeUnexpectedRecordShapeUnexpectedSequenceShape BadSelectorBadInstantiationCaptured BadProofNoAbsBadProofTyVars KindMismatchNotEnoughArgumentsInKindBadApplicationFreeTypeVariableBadTypeApplicationRepeatedVariableInForallBadMatchEmptyArmUndefinedTypeVaraibleUndefinedVariableProofObligationsametcExprtcDeclstcModule $fMonadTcM$fApplicativeTcM $fFunctorTcM $fSameTParam $fSameSchema $fSameType$fSame[] $fShowErrorUnificationErrorUniTypeMismatchUniKindMismatchUniTypeLenMismatch UniRecursiveUniNonPolyDepends UniNonPolyResultOKMGUuniErroremptyMGUmgumguManybindVar $fMonadResult$fApplicativeResult$fFunctorResultHasVarsIfExprIfExpr'IfReturn ImpossibleKVar:+:-:*DivMod:^^MinMaxWidth LenFromThen LenFromThenToFin:==:>=:>:==::>::&&:||NotPFalsePTrueUserNameSysNamezeroonetwoinfcryAndscryOrs cryPropExprs cryExprExprscryRebuildExpr cryExprFVS cryPropFVS composeSubstcryLet doAppSubstppNameppProp ppPropPrecppExpr ppExprPrecppIfExprppIf $fHasVarsProp $fHasVarsExpr $fHasVarsBool$fApplicativeIfExpr'$fFunctorIfExpr'$fMonadIfExpr' $fOrdExpr $fEqIfExpr'SignPosNeg crySimpExprcrySimpExprMaybe otherSignsignedsplitSumnormSumcrySimpExprStepcrySimpExprStep1 $fShowSign propToProp'ppProp'$fHasVarsIfExpr'$fEqAtomcryDefinedProp cryDefined crySimplifycrySimplifyMaybecrySimpPropExprcrySimpPropExprMaybeNonLinS nonLinProp apSubstNLlookupNL nonLinSubstinitialNonLinS $fShowNonLinSExportM exportProp runExportM exportPropM exportTypeM importProp importTypeIntervaliLoweriUpperIntervalUpdateNoChangeInvalidInterval NewIntervals typeIntervalupdateIntervalcomputePropIntervals propInterval ppIntervals ppIntervaliIsExactiIsFin iDisjoint iIntersectiAnyiAnyFiniConstiAddiMuliExpiMiniMaxiSubiDiviModiWidth iLenFromTheniLenFromThenTo $fEqInterval$fShowInterval$fShowIntervalUpdate fastTypeOf fastSchemaOfsplitVarSummandssplitVarSummandsplitConstSummandsplitConstFactor desugarPropifPropToSmtLibsmtName smtFinNamegetValgetValscryImproveModel TestReport reportResult reportPropreportTestsRunreportTestsPossibleTestSpectestFntestProp testTotal testPossibletestRptProgresstestClrProgresstestRptFailuretestRptSuccess TestResult FailFalse FailErrorisPass runOneTest testableTypetypeSize typeValuesrunTests IfaceDecl ifDeclName ifDeclSig ifDeclPragmas ifDeclInfix ifDeclFixity ifDeclDoc IfaceNewtype IfaceTySyn IfaceDeclsifTySyns ifNewtypesifDeclsIface ifModNameifPublic ifPrivate ifTySynName mkIfaceDeclgenIface ifacePrimMap$fMonoidIfaceDecls$fShowIfaceDecl$fGenericIfaceDecl$fNFDataIfaceDecl$fShowIfaceDecls$fGenericIfaceDecls$fNFDataIfaceDecls $fShowIface$fGenericIface $fNFDataIface rewModule$fTrieMapRewMap'(,,)EvalEnvenvVarsenvTypesReadEnvemptyEnv lookupVarbindType lookupType$fMonoidEvalEnv$fGenericEvalEnv$fNFDataEvalEnvevalType evalValType evalNumTypeevalTF modExportstnamesNTnamesDsnamesD allNamesDnamesBnamesDefnamesEnamesPsnamesPnamesMnamesArm boundNamesnamesTtnamesDstnamesDtnamesB tnamesDeftnamesEtnamesTItnamesPtnamesMtnamesStnamesCtnamesTMultipleSignaturesSignatureNoBind PragmaNoBindMultipleFixities FixityNoBind MultipleDocsRemovePatternsremovePatterns $fPPError $fMonadNoPatM$fApplicativeNoPatM$fFunctorNoPatM$fRemovePatterns[]$fRemovePatternsModule$fRemovePatternsExpr$fRemovePatternsProgram$fGenericError $fNFDataError ImportIface BindsNames namingEnvBuildNamingEnvrunBuildInModule NamingEnvneExprsneTypesneFixitymerge toPrimMap toNameDisp visibleNamesqualify filterNames singletonT singletonE shadowing travNamingEnv namingEnv' interpImportunqualifiedEnv$fBindsNamesInModule$fBindsNamesInModule0$fBindsNamesInModule1$fBindsNamesModule$fBindsNamesTParam$fBindsNamesInModule2$fBindsNamesImportIface$fBindsNamesSchema$fBindsNames[]$fBindsNamesMaybe$fBindsNamesNamingEnv$fMonoidBuildNamingEnv$fMonoidNamingEnv$fShowNamingEnv$fGenericNamingEnv$fNFDataNamingEnv$fFunctorInModule$fTraversableInModule$fFoldableInModule$fShowInModule TyFunName UserTyFun BuiltInTyFunConstraintSourceCtComprehension CtSplitPat CtTypeSigCtInst CtSelector CtExactType CtEnumeration CtDefaultingCtPartialTypeFun CtImprovement CtPatternErrorMsgTooManyTypeParamsTooManyTySynParamsTooFewTySynParamsRepeatedTyParamsRepeatedDefinitionsRecursiveTypeDeclsUndefinedTypeSynonymUndefinedTypeParamMultipleTypeParamDefs RecursiveType UnsolvedGoalUnsolvedDelayedCtUnexpectedTypeWildCardTypeVariableEscaped NotForAllUnusableFunctionTooManyPositionalTypeParams%CannotMixPositionalAndNamedTypeParams AmbiguousTypeWarningDefaultingKindDefaultingWildType DefaultingToSolvedUnsolved Unsolvable DelayedCt dctSource dctForalldctAsmpsdctGoalsHasGoalhasNamehasGoalGoal goalSource goalRangegoalGoalsVarTypeExtVarCurSCC SolverConfig solverPath solverArgs solverVerbose emptyGoals nullGoals fromGoals insertGoal addTVarsDescsppUse $fPPSolved$fPPConstraintSource $fPPWarning$fTVarsDelayedCt$fTVarsHasGoal $fTVarsGoal $fTVarsGoals$fFVSDelayedCt $fFVSGoal $fFVSError $fTVarsError $fFVSWarning$fTVarsWarning$fTVarsConstraintSource $fPPTyFunName$fShowSolverConfig$fGenericSolverConfig$fNFDataSolverConfig $fShowWarning$fGenericWarning$fNFDataWarning$fShowTyFunName$fGenericTyFunName$fNFDataTyFunName$fShowConstraintSource$fGenericConstraintSource$fNFDataConstraintSource $fShowGoal $fGenericGoal $fNFDataGoal $fShowSolved$fShowDelayedCt$fGenericDelayedCt$fNFDataDelayedCt $fShowHasGoal $fShowGoals classStep expandPropcryIsFin cryIsFinTypeDebugLogdebugLog debugLogListSolverlogger DefinedPropdpData dpSimpPropdpSimpExprProp knownDefined numericRight simplifyProps assumePropsminimizeContradictionSimpDefgetModel getIntervals withSolver withScopecheck debugBlock$fDebugLogProp$fDebugLogSubst$fDebugLogGoal$fDebugLogType $fDebugLogDoc$fDebugLogMaybe $fDebugLog[]$fDebugLogChar $fHasPropGoal $fHasPropType $fShowScope $fShowVarInfoLkpTyVar TLocalVar TOuterVarKRW typeParamsKRO lazyTVars allowWildKindMKMunKMRWiErrors iWarningsiSubst iExistTVars iSolvedHas iNameSeedsiCtsiHasCtsiSupplyROiRangeiVarsiTVarsiTSyns iNewtypesiSolvedHasLazy iMonoBindsiSolver iPrimNamesDefLocIsLocal IsExternalInferMIMunIM InferOutput InferFailedInferOK NameSeedsseedTVarseedGoal InferInputinpRangeinpVarsinpTSyns inpNewtypes inpNameSeeds inpMonoBindsinpSolverConfig inpPrimNames inpSupply nameSeeds runInferMioinRange inRangeMbcurRange recordError recordWarning getSolver getPrimMapnewGoalnewGoalsgetGoalsaddGoals collectGoals newHasGoal addHasGoal getHasGoals solveHasGoalnewName newGoalNamenewTVarnewTVar' newTParamnewTypeunify applySubstgetSubst extendSubst varsWithAsmps lookupTVar lookupTSyn lookupNewtypeexistVargetTSyns getNewtypesgetTVarsgetBoundInScope getMonoBindscheckTShadowing withTParam withTParams withTySyn withNewtype withVarType withVarTypeswithVar withMonoType withMonoTypes withDecls inNewScoperunKindM kLookupTyVarkWildOK kRecordErrorkRecordWarningkNewType kLookupTSynkLookupNewtype kExistTVar kInstantiateTkSetKindkInRange kNewGoals kInInferM $fMonadKindM$fApplicativeKindM$fFunctorKindM$fFreshMInferM$fMonadFixInferM $fMonadInferM$fApplicativeInferM$fFunctorInferM$fShowNameSeeds$fGenericNameSeeds$fNFDataNameSeeds$fShowInferInput$fShowInferOutputFromDecltoBindtoTyDecl isTopDeclTyDeclTSNT orderTyDecls orderBindsmkScc combineMapscombine duplicates$fFromDeclDecl$fFromDeclTopDeclinstantiateWith tryHasGoal widthIdenttranslateExprToNumT ParseError HappyError HappyErrorMsgppError parseModName parseHelpNameparseProgramWith parseModule parseProgram parseExprWith parseExpr parseDeclWith parseDeclparseDeclsWith parseDeclsparseLetDeclWith parseLetDecl parseReplWith parseReplparseSchemaWith parseSchema IncludeError IncludeFailedIncludeParseError IncludeCycleremoveIncludesModuleppIncludeError $fMonadNoIncM$fApplicativeNoIncM$fFunctorNoIncM$fShowIncludeError$fGenericIncludeError$fNFDataIncludeErrorRenamerenameRenameMRenamerWarningSymbolShadowed RenamerError MultipleSyms UnboundExpr UnboundTypeOverlappingSyms ExpectedValue ExpectedType FixityErrorInvalidConstraintMalformedBuiltinBoundReservedType runRenamer shadowNamescheckNamingEnv renameModule renameVar renameType $fRenameTySyn $fRenameMatch$fRenameTypeInst $fRenameExpr$fRenamePattern$fRenameBindDef $fRenameBind $fRenameType $fRenameProp$fRenameTParam$fRenameSchema$fRenameNewtype $fRenameDecl$fRenameTopDecl$fFreshMRenameM$fMonadRenameM$fApplicativeRenameM$fFunctorRenameM$fMonoidRenameM$fPPRenamerWarning$fPPRenamerError$fShowRenamerError$fGenericRenamerError$fNFDataRenamerError$fShowRenamerWarning$fGenericRenamerWarning$fNFDataRenamerWarning $fEqEnvCheck$fShowEnvChecktryRewritePropAsSubstwfTypeFunctionwfTypesimplifyAllConstraintsproveImplicationimproveByDefaultingWithdefaultReplExprsimpType simpTypeMaybeGen randomValue randomBit randomWord randomStreamrandomSequence randomTuple randomRecordBinArithUnaryGenUnaryBinary GenBinaryevalPrim primTable ecDemoteV divModPolymodExp doubleAndAddbinaryunary liftBinArith arithBinary arithUnarylg2divWrapmodWrap lexCompare zipLexComparecmpOrder withOrdermaxVminVfunCmpzeroVjoinVsplitAtVecSplitV infChunksOf finChunksOfccatV logicBinary logicUnary logicShiftshiftLWshiftLSshiftRWshiftRSrotateLWrotateLSrotateRWrotateRS indexPrimOne indexFront indexBack indexPrimManyindexFrontRangeindexBackRange fromThenVfromToV fromThenToVrandomV moduleEnvevalExpr evalDecls$fMonoidListEnv$fApplicativeZList$fFunctorZList traverseSndselectV asWordListatV_listatViteAtV replicateVnthnthVmapVcatVdropVtakeVsExpsLg2cmpValuecmpEqcmpNotEqcmpLtcmpGtcmpLtEqcmpGtEq cmpBinaryerrorVaddPolyitesdegreemdpidxdivx checkSchema checkTySyn checkNewtype checkType inferModulemkPrimdesugarLiteralappTys inferTyParamcheckTypeOfKindinferEcheckE expectSeq expectTuple expectRec expectFin expectFun checkHasTypecheckFunsmallestcheckPinferP inferMatch inferCArm inferBinds guessTypesimpBind generalize checkMonoB checkSigBinferDstcPanic ppWarning DynamicEnvDEnvdeNamesdeDeclsdeEnv LoadedModulelmName lmFilePath lmInterfacelmModule LoadedModulesgetLoadedModulesCoreLint NoCoreLint ModuleEnvmeLoadedModules meNameSeeds meEvalEnvmeFocusedModule meSearchPathmeDynEnv meMonoBindsmeSolverConfig meCoreLintmeSupplyresetModuleEnvinitialModuleEnv focusModule loadedModules focusedEnv dynamicEnv qualifiedEnvisLoaded lookupModuleaddLoadedModuleremoveLoadedModule deIfaceDecls$fMonoidDynamicEnv$fMonoidLoadedModules$fGenericCoreLint$fNFDataCoreLint$fShowLoadedModule$fGenericLoadedModule$fNFDataLoadedModule$fShowLoadedModules$fGenericLoadedModules$fNFDataLoadedModules$fGenericDynamicEnv$fNFDataDynamicEnv$fGenericModuleEnv$fNFDataModuleEnvModuleMModuleT unModuleT roLoading ModuleWarningTypeCheckWarningsRenamerWarnings ModuleErrorModuleNotFound CantFindFile OtherIOErrorModuleParseErrorRecursiveModules RenamerErrors NoPatErrorsNoIncludeErrorsTypeCheckingFailed OtherFailureModuleNameMismatchDuplicateModuleName ImportSource FromModule FromImportimportedModulemoduleNotFound cantFindFile otherIOErrormoduleParseErrorrecursiveModules renamerErrors noPatErrorsnoIncludeErrorstypeCheckingFailedmoduleNameMismatchduplicateModuleNamewarntypeCheckWarningsrenamerWarningsemptyRO runModuleT runModuleM getModuleEnv setModuleEnvmodifyModuleEnv loadingImport loadingModule interactiveloadinggetImportSourcegetIface getNameSeeds getSupply setMonoBinds setNameSeeds setSupply unloadModule loadedModule modifyEvalEnv getEvalEnvgetFocusedModulesetFocusedModule getSearchPathwithPrependedSearchPath getFocusedEnvgetQualifiedEnv getDynEnv setDynEnv setSolvergetSolverConfig$fFreshMModuleT$fMonadTModuleT$fMonadModuleT$fApplicativeModuleT$fFunctorModuleT$fPPModuleWarning$fPPModuleError$fNFDataModuleError$fPPImportSource$fEqImportSource$fShowImportSource$fGenericImportSource$fNFDataImportSource$fShowModuleError$fShowModuleWarning$fGenericModuleWarning$fNFDataModuleWarningTCActiontcActiontcLintertcPrimsTCLinter lintCheck lintModulenoPatloadModuleByPath loadImport loadModulefullyQualified importIface importIfaces moduleFile findModulefindFile addPreludeloadDeps getLocalEnv checkExpr checkDecls checkModule exprLinter declsLinter moduleLinter typecheck genInferInput ModuleRes ModuleCmdSpecMSpecT SpecCacherunSpecT liftSpecT getSpecCache setSpecCachemodifySpecCachemodify specializespecializeExprspecializeMatchwithDeclGroupsspecializeEWherespecializeDeclGroupsspecializeConstdestEProofApps destETApps destEProofAbs destETAbs freshNameinstantiateSchemainstantiateExpr allDeclGroupsallLoadedModulesallPublicNamesEnvFinTypeFTBitFTSeqFTTupleFTRecord ProverResult AllSatResult ThmResult EmptyResult ProverError ProverCommand pcQueryType pcProverName pcVerbose pcExtraDecls pcSmtFilepcExprpcSchema QueryTypeSatQuery ProveQuerySatNumAllSatSomeSat SatResult proverConfigs proverNames lookupProver satSMTResultsallSatSMTResults thmSMTResults proverErrorsatProvesatProveOffline protectStack parseValues parseValuenumTypefinType unFinType predArgTypes forallFinType existsFinTypeevalSel evalDeclGroupevalDecl copyBySchema copyByTypeevalComp branchEnvs evalMatch $fMonoidEnv $fShowSatNum$fShowQueryTypeSmoke Z3NotFound OptionDescroptName optDefaultoptCheckoptHelpoptEffEnvVal EnvStringEnvProgEnvNumEnvBool REPLException FileNotFoundDirectoryNotFound NoPatErrorNoIncludeErrorModuleSystemError EvalPolyErrorTypeNotTestableREPLunREPLlNamelPathrunREPLraisecatchrethrowEvalError getPrompt setLoadedMod getLoadedMod setSearchPathprependSearchPathshouldContinuestop unlessBatchasBatch disableLet enableLet getLetEnabledupdateREPLTitlesetUpdateREPLTitle setPutStr getPutStrrPutStr rPutStrLnrPrintgetVars getExprNames getTypeNamesgetPropertyNamesuniqifysetUser tryGetUsergetUser userOptions getUserSatNum whenDebug smokeTest $fPPSmoke$fPPREPLException$fExceptionREPLException $fFreshMREPL$fMonadBaseControlIOREPL$fMonadBaseIOREPL $fMonadIOREPL $fMonadREPL$fApplicativeREPL $fFunctorREPL$fShowREPLException $fShowEnvVal $fShowSmoke $fEqSmokeQCModeQCRandom QCExhaust CommandBodyExprArg FileExprArgDeclsArg ExprTypeArg FilenameArg OptionArgShellArgNoArg CommandDescrcNamescBodycHelpCommand AmbiguousUnknown runCommandqcCmdsatCmdproveCmdonlineProveSatofflineProveSat moduleCmd loadPreludeloadCmd setOptionCmd handleCtrlC replParse replParseExprinteractiveConfig liftModuleCmdmoduleCmdResult replCheckExpr replEvalExprsanitize splitCommand findCommandfindCommandExact findNbCommand parseCommand$fOrdCommandDescr$fEqCommandDescr$fShowCommandDescr $fEqQCMode $fShowQCModehashbranchdirtybaseGHC.BaseNothingcatchIObindirlibdirdatadir libexecdir sysconfdir getBinDir getLibDir getDataDir getLibexecDir getSysconfDirgetDataFileName CryptolPanicpanicLocpanicMsgmarkdownlatexBlockCodeCommentpreProc toCryptolmkTokenOpOtherVirtualExplicit splitQual dropWhite byteForCharPlusMinusMulExpEqualLEQGEQ ComplementHash AlexInputInpalexPosalexInputPrevCharinputLexSNormal InCommentInStringInCharAction startComment endComent addToCommentstartEndComment startString endString addToString startCharendChar addToChar mkQualIdentmkQualOpemitemitSnumToken fromDecDigit fromHexDigit alexGetByte isExplicit startsLayoutlayoutvirt $fPPTokenAlexAcc AlexAccNone AlexAccSkip AlexLastAccAlexNone AlexLastSkip AlexReturnAlexEOF AlexErrorAlexSkip AlexTokenAlexAddrAlexA# alex_base alex_table alex_check alex_deflt alex_accept stateToIntcommentstring alex_action_0 alex_action_1 alex_action_2 alex_action_3 alex_action_4 alex_action_5 alex_action_6 alex_action_7 alex_action_8 alex_action_9alex_action_10alex_action_11alex_action_12alex_action_13alex_action_14alex_action_15alex_action_16alex_action_17alex_action_18alex_action_19alex_action_20alex_action_21alex_action_22alex_action_23alex_action_24alex_action_25alex_action_26alex_action_27alex_action_28alex_action_29alex_action_30alex_action_31alex_action_32alex_action_33alex_action_34alex_action_35alex_action_36alex_action_37alex_action_38alex_action_39alex_action_40alex_action_41alex_action_42alex_action_43alex_action_44alex_action_45alex_action_46alex_action_47alex_action_48alex_action_49alex_action_50alex_action_51alex_action_52alex_action_53alex_action_54alex_action_55alex_action_56alex_action_57alex_action_58alex_action_59alex_action_60alex_action_61alex_action_62alex_action_63alex_action_64alex_action_65alex_action_66alex_action_67alex_action_68alex_action_69alex_action_70alex_action_71alex_action_72alex_action_73alex_action_74alex_action_75alex_action_76alex_action_77alexIndexInt16OffAddralexIndexInt32OffAddr quickIndexalexScan alexScanUser alex_scan_tkniUnbox nameVariant nameVariantsppLppNamedppFixityppPragmappNumLitwrapisEAppasEAppsnUniquenInfonIdentnFixitynLocunSupplyGHC.ErrerrorupdSub checkTypeIsexprType exprSchema convertible checkDeclTcMwoProofObligationsroTVarsroAsmpsroVarsSametMonoisMonocheckDeclGroup checkMatchcheckArmrunTcM reportErrorwithTVarwithAsmpwithVarsproofObligationnames apSubstAtompFalsepTruepNotpAndpOrpIfpAtompEqghc-prim GHC.Classes==pGeq>=pGtpInfeNoInfIAtomAFinAGtAEqppAtommkIfpIsNat _pIsGtThanNat _pNatIsGtThan pKnownFin pKnownInf balanceEq crySimpStepcryRearrangeAndcryRearrangeOr cryIsDefn cryRearrangecryAndcryOr cryKnownFin GHC.TypesTrueFalsecryNotcryIsEqcryIsGtcryNatGtcryGtNatcryNoInfcryNatOp PropOrderingcmpAndcmpOrcryIsNatUpdatedJust mApSubstNL isNonLinOpnextName nonLinExprsnlKnownnlTodoNonLinM SubstOneRes trie_empty trie_insert trie_delete trie_lookuprunNL mApSubstOneNL nlImplied nonLinPropM nonLinExprMnameExpr finishTodos typeSelect desugarExprtoSubst checkUnsatgetCounterExample cryMustEqualK cryMustEqualVcryCheckLinRellinRel propToSmtLib exprToSmtLibifaceDeclsPrimMapinLocalMRewMapRewMap'RMnewTopOrLocalNamerewErewMrewDrewDef rewDeclGroup splitTParams splitTAppnotFun annotTopDsannotDsannotDannotB checkSigstoSigtoPragmatoFixitytoDocserrorsNoPatMunMAnnotMap simpleBindsel splitSimplePnoPatEnoPatFunnoPatArmnoPatMnoMatchBnoMatchDnoPatDs noPatTopDs noPatProg noPatModule checkFixs checkDocsgetRange runNoPatMsolvedsolveArithInst solveArithSeq solveCmpInst scopeNames scopeNonLinSscopeIntervals scopeAssertedVarInfosolverdeclaredSimpPropeliminateSimpleGEQscopeAssertSimpPropviEmptyviElemviInsertviAssertSimpPropviPushviPopviUnmarkedNames getNLSubst declareVarassertassertSimpPropprove getImpSubstScopecurScope otherScopesHasPropgetProp unSimpPropsimpProp scopeEmpty scopeElem scopeInsertscopeAssertNew scopeAssertviAssertsolPushsolPopIntinstantiateWithNamesinstantiateWithPosdoInst solveSelector recordType tupleTypelistTypeimproveSelector anonRecord mkPrimDeclmkDocParseMPunP parseStringparselexerP happyError errorMessage customError mkModNamemkSchemagetNamegetNumgetStrnumLitintValmkFixity mkTupleSel fromStrLitvalidDemotedTypemkEAppunOpbinOpeFromTo exprToNumT exportDecl exportNewtype changeExport mkTypeInstmkTParammkTySynpolyTermmkPoly mkPropertymkProp arithIdentfinIdentcmpIdent$fApplicativeParseM$fFunctorParseM $fMonadParseM$fPPParseError HappyAddrHappyA#HappyStk Happy_IntList HappyConsHappyAny HappyAbsSyn happyIn15 happyOut15 happyIn16 happyOut16 happyIn17 happyOut17 happyIn18 happyOut18 happyIn19 happyOut19 happyIn20 happyOut20 happyIn21 happyOut21 happyIn22 happyOut22 happyIn23 happyOut23 happyIn24 happyOut24 happyIn25 happyOut25 happyIn26 happyOut26 happyIn27 happyOut27 happyIn28 happyOut28 happyIn29 happyOut29 happyIn30 happyOut30 happyIn31 happyOut31 happyIn32 happyOut32 happyIn33 happyOut33 happyIn34 happyOut34 happyIn35 happyOut35 happyIn36 happyOut36 happyIn37 happyOut37 happyIn38 happyOut38 happyIn39 happyOut39 happyIn40 happyOut40 happyIn41 happyOut41 happyIn42 happyOut42 happyIn43 happyOut43 happyIn44 happyOut44 happyIn45 happyOut45 happyIn46 happyOut46 happyIn47 happyOut47 happyIn48 happyOut48 happyIn49 happyOut49 happyIn50 happyOut50 happyIn51 happyOut51 happyIn52 happyOut52 happyIn53 happyOut53 happyIn54 happyOut54 happyIn55 happyOut55 happyIn56 happyOut56 happyIn57 happyOut57 happyIn58 happyOut58 happyIn59 happyOut59 happyIn60 happyOut60 happyIn61 happyOut61 happyIn62 happyOut62 happyIn63 happyOut63 happyIn64 happyOut64 happyIn65 happyOut65 happyIn66 happyOut66 happyIn67 happyOut67 happyIn68 happyOut68 happyIn69 happyOut69 happyIn70 happyOut70 happyIn71 happyOut71 happyIn72 happyOut72 happyIn73 happyOut73 happyIn74 happyOut74 happyIn75 happyOut75 happyIn76 happyOut76 happyIn77 happyOut77 happyIn78 happyOut78 happyIn79 happyOut79 happyIn80 happyOut80 happyIn81 happyOut81 happyIn82 happyOut82 happyIn83 happyOut83 happyIn84 happyOut84 happyIn85 happyOut85 happyIn86 happyOut86 happyIn87 happyOut87 happyIn88 happyOut88 happyIn89 happyOut89 happyIn90 happyOut90 happyIn91 happyOut91 happyIn92 happyOut92 happyIn93 happyOut93 happyIn94 happyOut94 happyIn95 happyOut95 happyIn96 happyOut96 happyIn97 happyOut97 happyInTok happyOutTokhappyActOffsetshappyGotoOffsetshappyDefActions happyCheck happyTablehappyReduceArr happy_n_termshappy_n_nontermshappyReduce_12happyReduction_12happyReduce_13happyReduction_13happyReduce_14happyReduction_14happyReduce_15happyReduction_15happyReduce_16happyReduction_16happyReduce_17happyReduction_17happyReduce_18happyReduction_18happyReduce_19happyReduction_19happyReduce_20happyReduction_20happyReduce_21happyReduction_21happyReduce_22happyReduction_22happyReduce_23happyReduction_23happyReduce_24happyReduction_24happyReduce_25happyReduction_25happyReduce_26happyReduction_26happyReduce_27happyReduction_27happyReduce_28happyReduction_28happyReduce_29happyReduction_29happyReduce_30happyReduction_30happyReduce_31happyReduction_31happyReduce_32happyReduction_32happyReduce_33happyReduction_33happyReduce_34happyReduction_34happyReduce_35happyReduction_35happyReduce_36happyReduction_36happyReduce_37happyReduction_37happyReduce_38happyReduction_38happyReduce_39happyReduction_39happyReduce_40happyReduction_40happyReduce_41happyReduction_41happyReduce_42happyReduction_42happyReduce_43happyReduction_43happyReduce_44happyReduction_44happyReduce_45happyReduction_45happyReduce_46happyReduction_46happyReduce_47happyReduction_47happyReduce_48happyReduction_48happyReduce_49happyReduction_49happyReduce_50happyReduction_50happyReduce_51happyReduction_51happyReduce_52happyReduction_52happyReduce_53happyReduction_53happyReduce_54happyReduction_54happyReduce_55happyReduction_55happyReduce_56happyReduction_56happyReduce_57happyReduction_57happyReduce_58happyReduction_58happyReduce_59happyReduction_59happyReduce_60happyReduction_60happyReduce_61happyReduction_61happyReduce_62happyReduction_62happyReduce_63happyReduction_63happyReduce_64happyReduction_64happyReduce_65happyReduction_65happyReduce_66happyReduction_66happyReduce_67happyReduction_67happyReduce_68happyReduction_68happyReduce_69happyReduction_69happyReduce_70happyReduction_70happyReduce_71happyReduction_71happyReduce_72happyReduction_72happyReduce_73happyReduction_73happyReduce_74happyReduction_74happyReduce_75happyReduction_75happyReduce_76happyReduction_76happyReduce_77happyReduction_77happyReduce_78happyReduction_78happyReduce_79happyReduction_79happyReduce_80happyReduction_80happyReduce_81happyReduction_81happyReduce_82happyReduction_82happyReduce_83happyReduction_83happyReduce_84happyReduction_84happyReduce_85happyReduction_85happyReduce_86happyReduction_86happyReduce_87happyReduction_87happyReduce_88happyReduction_88happyReduce_89happyReduction_89happyReduce_90happyReduction_90happyReduce_91happyReduction_91happyReduce_92happyReduction_92happyReduce_93happyReduction_93happyReduce_94happyReduction_94happyReduce_95happyReduction_95happyReduce_96happyReduction_96happyReduce_97happyReduction_97happyReduce_98happyReduction_98happyReduce_99happyReduction_99happyReduce_100happyReduction_100happyReduce_101happyReduction_101happyReduce_102happyReduction_102happyReduce_103happyReduction_103happyReduce_104happyReduction_104happyReduce_105happyReduction_105happyReduce_106happyReduction_106happyReduce_107happyReduction_107happyReduce_108happyReduction_108happyReduce_109happyReduction_109happyReduce_110happyReduction_110happyReduce_111happyReduction_111happyReduce_112happyReduction_112happyReduce_113happyReduction_113happyReduce_114happyReduction_114happyReduce_115happyReduction_115happyReduce_116happyReduction_116happyReduce_117happyReduction_117happyReduce_118happyReduction_118happyReduce_119happyReduction_119happyReduce_120happyReduction_120happyReduce_121happyReduction_121happyReduce_122happyReduction_122happyReduce_123happyReduction_123happyReduce_124happyReduction_124happyReduce_125happyReduction_125happyReduce_126happyReduction_126happyReduce_127happyReduction_127happyReduce_128happyReduction_128happyReduce_129happyReduction_129happyReduce_130happyReduction_130happyReduce_131happyReduction_131happyReduce_132happyReduction_132happyReduce_133happyReduction_133happyReduce_134happyReduction_134happyReduce_135happyReduction_135happyReduce_136happyReduction_136happyReduce_137happyReduction_137happyReduce_138happyReduction_138happyReduce_139happyReduction_139happyReduce_140happyReduction_140happyReduce_141happyReduction_141happyReduce_142happyReduction_142happyReduce_143happyReduction_143happyReduce_144happyReduction_144happyReduce_145happyReduction_145happyReduce_146happyReduction_146happyReduce_147happyReduction_147happyReduce_148happyReduction_148happyReduce_149happyReduction_149happyReduce_150happyReduction_150happyReduce_151happyReduction_151happyReduce_152happyReduction_152happyReduce_153happyReduction_153happyReduce_154happyReduction_154happyReduce_155happyReduction_155happyReduce_156happyReduction_156happyReduce_157happyReduction_157happyReduce_158happyReduction_158happyReduce_159happyReduction_159happyReduce_160happyReduction_160happyReduce_161happyReduction_161happyReduce_162happyReduction_162happyReduce_163happyReduction_163happyReduce_164happyReduction_164happyReduce_165happyReduction_165happyReduce_166happyReduction_166happyReduce_167happyReduction_167happyReduce_168happyReduction_168happyReduce_169happyReduction_169happyReduce_170happyReduction_170happyReduce_171happyReduction_171happyReduce_172happyReduction_172happyReduce_173happyReduction_173happyReduce_174happyReduction_174happyReduce_175happyReduction_175happyReduce_176happyReduction_176happyReduce_177happyReduction_177happyReduce_178happyReduction_178happyReduce_179happyReduction_179happyReduce_180happyReduction_180happyReduce_181happyReduction_181happyReduce_182happyReduction_182happyReduce_183happyReduction_183happyReduce_184happyReduction_184happyReduce_185happyReduction_185happyReduce_186happyReduction_186happyReduce_187happyReduction_187happyReduce_188happyReduction_188happyReduce_189happyReduction_189happyReduce_190happyReduction_190happyReduce_191happyReduction_191happyReduce_192happyReduction_192happyReduce_193happyReduction_193happyReduce_194happyReduction_194happyReduce_195happyReduction_195happyReduce_196happyReduction_196happyReduce_197happyReduction_197happyReduce_198happyReduction_198happyReduce_199happyReduction_199happyReduce_200happyReduction_200happyReduce_201happyReduction_201happyReduce_202happyReduction_202happyReduce_203happyReduction_203happyReduce_204happyReduction_204happyReduce_205happyReduction_205happyReduce_206happyReduction_206happyReduce_207happyReduction_207happyReduce_208happyReduction_208happyReduce_209happyReduction_209happyReduce_210happyReduction_210happyReduce_211happyReduction_211happyReduce_212happyReduction_212happyReduce_213happyReduction_213happyReduce_214happyReduction_214happyReduce_215happyReduction_215happyReduce_216happyReduction_216happyReduce_217happyReduction_217happyReduce_218happyReduction_218happyReduce_219happyReduction_219happyReduce_220happyReduction_220happyReduce_221happyReduction_221happyReduce_222happyReduction_222happyReduce_223happyReduction_223happyReduce_224happyReduction_224happyReduce_225happyReduction_225happyReduce_226happyReduction_226happyReduce_227happyReduction_227happyReduce_228happyReduction_228happyReduce_229happyReduction_229happyReduce_230happyReduction_230happyReduce_231happyReduction_231happyReduce_232happyReduction_232happyReduce_233happyReduction_233happyReduce_234happyReduction_234happyReduce_235happyReduction_235happyReduce_236happyReduction_236happyReduce_237happyReduction_237happyReduce_238happyReduction_238happyReduce_239happyReduction_239happyReduce_240happyReduction_240happyReduce_241happyReduction_241happyReduce_242happyReduction_242happyReduce_243happyReduction_243happyReduce_244happyReduction_244happyReduce_245happyReduction_245happyReduce_246happyReduction_246happyReduce_247happyReduction_247happyReduce_248happyReduction_248happyReduce_249happyReduction_249happyReduce_250happyReduction_250 happyNewToken happyError_ happyThen happyReturn happyThen1 happyReturn1 happyError'vmoduleprogram programLayoutexprdecldecls declsLayoutletDeclreplschemamodNamehelpNamehappySeqaddImplicitIncludes happyParse happyAccept happyDoActionindexShortOffAddr happyShifthappySpecReduce_0happySpecReduce_1happySpecReduce_2happySpecReduce_3 happyReducehappyMonadReducehappyMonad2Reduce happyDrop happyDropStk happyGoto happyFail notHappyAtAll happyTcHack happyDoSeq happyDontSeqenvSeen envIncPath getIncPath withIncPathNoIncM fromIncPath includeFailedpushPath failsWith collectErrorsData.TraversablemapMnoIncludeModulenoIncludeProgram noIncTopDeclresolveInclude readInclude runNoIncM tryNoIncMCheckAll CheckOverlap CheckNonegetNS shadowNames'checkEnvcontainsOverlap typeExists mkFakeName renameSchema isReserved lookupFixityTOp renameMatch renamePatsEnvCheck unRenameM rwWarningsrwErrorsrwSupplyroLocroModroNamesroDisprecordcurLoclocatedwithLoc shadowNamesNS rnLocated translatePropisReservedTyConresolveTypeFixity infixPropsmkTInfixmkEInfixrenameOp renameArm patternEnvrnNamedrank tryRewriteEqallFin rewriteLHSimportSplitImps importImps tryGetModelproveImplicationIO simpGoals'simplifyConstraintTermssolveConstraints solveNumericscomputeImprovements improveByDefnimportSideConds_testSimpGoalsListEnvZList evalNewtype zipListEnvleVarsleTypesPureZip evalNewtypesgetZList toListEnv bindVarListtySynappTy doCheckType checkTyThing checkProp checkKindwritePreludeContentspreludeContentsUserEnv defaultRWmkPrompt mkUserEnv checkBase SmokeTest OptionMap eLoadedMod eContinueeIsBatch eModuleEnveUserEnvePutStr eLetEnabled eUpdateTitlegetRWmodifyRW modifyRW_ splitOptArgs mkOptionMap simpleOptcheckInfLength checkProverproverListString checkSatNumz3existscommands nbCommands nbCommandList cmdProveSatmkSolverResultreplCheckDeclsbindItVariablebindItVariables sanitizeEnduncons CommandMap commandListgenHelp getPPValOptsevalCmdrIdent specializeCmd typeOfCmd readFileCmd writeFileCmd reloadCmdeditCmdquitCmd browseCmd browseTSynsbrowseNewtypes browseVarshelpCmd runShellCmdcdCmd isNamePrefixreplParseInput replSpecExpritIdent replWriteFile replReadFile replEvalDeclreplEdittrim