Commit Graph

8 Commits

Author SHA1 Message Date
Iavor Diatchki
0d81f0ba25 Implement defaulting in the presence of overloaded literals. 2018-06-20 15:06:19 -07:00
Iavor Diatchki
33f0ab3979 Improved locations for defaulting warnings. 2018-06-19 17:28:59 -07:00
Trevor Elliott
f8e6582230 Update tests and output 2015-09-28 21:26:26 -07:00
Adam C. Foltzer
3d275ea44c add load targets to search path
Fixes a bug pointed out by @weaversa:
https://github.com/GaloisInc/cryptol/issues/127#issuecomment-64464455

In addition to the other search path changes in #127, we now will add
the directory containing files to be loaded to the search path. This
applies to:

- files loaded with a command line argument, like in the original
  comment
- arguments to `:l`, so for example `:l examples/DES.cry` would work
- batch file arguments, so for example running `cryptol -b
  /some/path/bar.cry` adds `/some/path` to the search path.
2015-02-17 15:27:59 -08:00
Trevor Elliott
41ca73ffaa Update tests for changes to inference
The changes didn't alter the behavior of the typechecker, only the
warning/error output, and the order of some variables when generalizing.
2014-12-30 10:43:38 -08:00
Adam C. Foltzer
284338c938 Add the mono-binds flag
When `:set mono-binds=on`, any local definitions lacking type
signatures will not be generalized (i.e., will be monomorphic). This
reduces what is in most cases unnecessary polymorphism that can give
rise to constraints that are difficult to solve. This also improves
the performance of the Cryptol interpreter by lifting many polymorphic
type applications out of the inner loops that are commonly defined as
bindings in `where` clauses.

The flag is on by default in the Cryptol REPL, and in most cases makes
it possible to leave out more type signatures in `where` clauses than
before. However, some programs really do rely on inferring polymorphic
types for local variables; in this case adding an explicit polymorphic
type signature to the local binding in question will make the program
typecheck.
2014-12-15 17:48:25 -08:00
Trevor Elliott
ee3647b814 Update renamer errors to clarify some funny situations
This tries to address #125 by making the errors from the renamer a little bit
more clear.

Squashed commit of the following:

commit 8afd3d7961b58df042fe801c3c5e1b9787f813bc
Author: Trevor Elliott <trevor@galois.com>
Date:   Wed Dec 3 19:33:59 2014 -0800

    Update tests for new renamer errors

commit 7cac01836d8943cf3b08d6715ac328e3b6658cef
Author: Trevor Elliott <trevor@galois.com>
Date:   Wed Dec 3 19:33:49 2014 -0800

    Add `at` on errors and warnings to be more consistent

commit 308908ba318a4cdc839710f66f1a487543f8c07e
Author: Trevor Elliott <trevor@galois.com>
Date:   Wed Dec 3 19:06:57 2014 -0800

    More consistent renamer warnings

commit be8100a78e9eaba6d554591121c24ed5dcd3c780
Author: Trevor Elliott <trevor@galois.com>
Date:   Wed Dec 3 18:56:53 2014 -0800

    More consistent error formatting from the renamer

commit 26c45c3b51e0bdbcf6a1431cab8e1eb8760ea0bb
Author: Trevor Elliott <trevor@galois.com>
Date:   Wed Dec 3 18:56:36 2014 -0800

    Remove an un-triggerable error

commit ccdb93e036ba1e111ccd977c8b3b35523f3c1bf0
Author: Trevor Elliott <trevor@galois.com>
Date:   Wed Dec 3 16:38:44 2014 -0800

    Try to give better errors for unbound identifiers

commit eb5784145985bb55c761088eaba27c67d08c1326
Author: Trevor Elliott <trevor@galois.com>
Date:   Wed Dec 3 16:38:23 2014 -0800

    Remove old TODOs about located errors

commit b984bb5f451f3aa7b4fc8f15167483c5142ee9a3
Author: Trevor Elliott <trevor@galois.com>
Date:   Wed Dec 3 14:37:34 2014 -0800

    Differentiate missing type and expression symbols

commit b9e6f13856db6765dced3cb9565cdc8387a7976d
Author: Trevor Elliott <trevor@galois.com>
Date:   Wed Dec 3 14:36:52 2014 -0800

    Remove a shadowing warning
2014-12-03 19:36:06 -08:00
Adam C. Foltzer
ba0a0e8576 Initial import from internal repo 2014-04-17 15:34:25 -07:00