Commit Graph

1264 Commits

Author SHA1 Message Date
Aaron Tomb
10240a62d6 Add note about Z3 version to README 2017-07-21 08:42:38 -07:00
Aaron Tomb
da04f374f4 Add Travis badge to README 2017-07-21 08:34:30 -07:00
Aaron Tomb
8aa497206c Re-enable prover identification in stats 2017-07-20 10:38:38 -07:00
Aaron Tomb
a04f236169 Update test output for SBV 7.0
With SBV 7.0, we get back satisfying assignments in a different order.
We should probably adjust this test to be less fragile eventually.
2017-07-20 09:33:56 -07:00
Aaron Tomb
d873664df4 Merge pull request #434 from LeventErkok/master
Modifications to make cryptol compile with SBV 7.0
2017-07-20 09:04:24 -07:00
Levent Erkok
5857477ab2 Modifications to make cryptol compile with SBV 7.0
Also, bumped up the version to 2.4.1
2017-07-18 10:25:00 -07:00
Aaron Tomb
25e2ba01c6 Disable tests on AppVeyor for now
More of the Makefile needs to be updated before tests will run
correctly.
2017-07-12 10:49:59 -07:00
Aaron Tomb
ec0b506230 Follow redirects when fetching Z3 2017-07-12 10:14:12 -07:00
Aaron Tomb
14ac49279a Run tests under AppVeyor 2017-07-12 09:54:20 -07:00
Iavor Diatchki
4a43c675d9 When checking a binding, treat schema validation constraints
just like any other constraint from the definition.

In particular, if the schema validity depends on an outer context,
the constraints should be solve in that outer context, not here.

Fixes #314
2017-07-10 17:35:49 -07:00
Iavor Diatchki
c836d8e356 Improve error message.
Fixes #383
2017-07-10 17:11:55 -07:00
Iavor Diatchki
e5fa174cbb Add some axioms about width.
Fixes #387
2017-07-10 16:59:03 -07:00
Iavor Diatchki
b5d6715b21 Add support for comments; panic on completely bogus inputs.
Note that we still do not check for errors in commands, perhaps we should?
2017-07-10 16:58:33 -07:00
Iavor Diatchki
affcc25156 Don't crash when we detect and error, tell the user instead!
Also, improve the printing of the errors a bit.
2017-07-10 11:59:39 -07:00
Iavor Diatchki
771c2deaa1 Slightly different error messages, should be OK. 2017-07-10 11:06:14 -07:00
Iavor Diatchki
1e4fb89f4c Fix test, due to changes in the Prelude. 2017-07-10 11:05:59 -07:00
Iavor Diatchki
0f825daf2f Bug fix: remember to pop-off the solver's context. 2017-07-10 11:05:47 -07:00
Iavor Diatchki
5a885e9f5a Check for consistency before improving.
We may want to do this more often, but it may have a performance penalty.

Anyway, we need this check here, because previously the code was assuming
that the goals are known to be consistent, and we are just wanting to
default them, which should never make them inconsistent, just more instantiated.

The current solution is a bit of a stop-gap, until we redo the defaulting
story, and separate it form improvement.
2017-07-10 10:59:40 -07:00
Iavor Diatchki
89f0af891a Report inconsistent constraints together. 2017-07-10 10:56:56 -07:00
Iavor Diatchki
ae3e0ea106 Add some functionality for simple checking of the consistency of goals. 2017-07-10 10:55:49 -07:00
Iavor Diatchki
04fbc4c1c2 Notice the fin inf is impossible. 2017-07-10 09:41:15 -07:00
Aaron Tomb
2d6dac4a23 Another Travis typo... 2017-07-07 15:28:52 -07:00
Aaron Tomb
ac214563f2 Put Z3 in $HOME/bin on Travis/Linux 2017-07-07 15:25:20 -07:00
Aaron Tomb
80faaa4819 Fix typo in Travis config 2017-07-07 15:11:25 -07:00
Aaron Tomb
aeeb938e18 Update Travis config to install Z3 2017-07-07 15:09:40 -07:00
Andrey Chudnov
6bdce04727 Extend built-in library caching to Cryptol::Extras 2017-07-07 14:25:22 -07:00
Aaron Tomb
48c4d764e1 Use built-in diff on Travis 2017-07-05 16:25:58 -07:00
Aaron Tomb
aa0d5179b8 Specify the diff program to use on Travis 2017-07-05 11:51:41 -07:00
Aaron Tomb
b6a0e7e3f6 Fix typo in Travis OS X script 2017-07-05 11:51:07 -07:00
Aaron Tomb
72592041f0 Back to make for AppVeyor 2017-07-05 11:26:30 -07:00
Aaron Tomb
28f037b17b Use install instead of build for AppVeyor 2017-07-05 11:16:52 -07:00
Aaron Tomb
84e0687df6 Fix typo in Travis config 2017-07-05 11:14:38 -07:00
Aaron Tomb
16e3ed809c Use cabal build instead of make for AppVeyor 2017-07-05 11:01:52 -07:00
Aaron Tomb
4a2f2f50e9 Add AppVeyor configuration 2017-07-05 10:57:46 -07:00
Aaron Tomb
e8a8b5292b Add OS X configuration for Travis 2017-07-05 10:27:08 -07:00
Aaron Tomb
16876426aa Run cabal update on Travis 2017-07-05 10:18:08 -07:00
Aaron Tomb
c5e44f694b Another attempt at Travis 2017-07-05 09:58:04 -07:00
Aaron Tomb
06ad707b61 Bump Travis GHC version 2017-07-05 09:39:35 -07:00
Aaron Tomb
d63c68351a Track both original and canonical module paths
Using canonical paths in error messages makes testing a pain. This
allows comparing canonical paths *and* passing all our tests. How about
that.
2017-06-28 16:18:34 -07:00
Aaron Tomb
9bbf422407 Canonicalize module path names earlier
This largely reverts 54831eace2 and takes
a different approach. This way path names are normalized before feeding
them to the parser, rather than when comparing the module to be loaded
with the module already loaded. This works better because it takes into
account the current directory at the time when `loadModuleByPath` is
called.
2017-06-28 15:50:02 -07:00
Aaron Tomb
54831eace2 Use canonical paths to check if module is loaded
Since multiple modules may import the same module, the module loading
process keeps track of whether a given module has been loaded already.
To do this, it looks up the module by name and, if found, compares the
paths of the two modules to check that they come from the same file.
However, these paths are not guaranteed to be normalized, so it can
sometimes print an error message when attempting to load the same module
from a file named in two different ways. This commit normalizes the file
paths before comparing them. Alternatively, it may make sense to enforce
an invariant throughout that module file paths are normalized, though
this may require care to avoid overly verbose messages.
2017-06-28 14:17:29 -07:00
Aaron Tomb
49e847387e Simplify some type signatures in examples
These examples weren't type checking, and now do, with type constraints
that are no more awkward, and arguably less awkward, than before.
2017-06-22 10:09:13 -07:00
Aaron Tomb
e282c65a7e Fix test failures from latest type checker changes
Recent changes resolved issue 002, so we no longer need to indicate that
it's expected to fail. Other small changes to the type checker have
made things like type variable numbers change slightly.
2017-06-20 10:08:36 -07:00
Iavor S. Diatchki
39b1e84dd3 When solving selectors, keep trying if any unifications happened 2017-06-16 16:05:51 -07:00
Iavor S. Diatchki
38f3a54a36 Comments, + apply the correct substitution 2017-06-16 16:04:56 -07:00
Iavor S. Diatchki
0985508bbc Add fin constraints on the message mart of trace. 2017-06-16 09:58:11 -07:00
Iavor S. Diatchki
509ef089c0 change in normalization of Min
Previously, we would factor out constants from `min`, now we push them in.

Thus:  `3 + min a b` becomes `min (3 + a) (3 + b)`.
This allows nested `min` to flow next to each other and interact.

We also add rules for moving constants out of nested `min`:

min a (min K b) ~> min K (min a b)

and another useful rule, which sort of factors out the constants again,
but notice that the result does not have a `min` in it.

min (K1 + a) (K2 + a) ~> min K1 K2 + a
2017-06-15 16:55:38 -07:00
Iavor S. Diatchki
fab66bbf36 New rule: min K1 a >= K2 ~> a >= K2 if K1 >= K2, and False otherwise 2017-06-15 16:51:16 -07:00
Iavor S. Diatchki
627d5aa269 Some code that is useful for tracing the simplifier when debugging. 2017-06-15 16:50:18 -07:00
Iavor S. Diatchki
7a42065a94 Just some comments that make it easy to disable defaulting. 2017-06-15 16:49:46 -07:00