Commit Graph

67 Commits

Author SHA1 Message Date
Guillaume Melquiond
abf9c043cf Update headers. 2019-02-11 15:35:11 +01:00
Raphael Rieu-Helft
17ed127006 Add support for partial functions
Program functions can be declared as partial with "let/val partial".
Similarly to "diverges", partial code cannot be ghost, however it does not need to be
explicitly specified as partial.

Fixes #184.
2018-09-28 10:31:26 +02:00
Guillaume Melquiond
b43e3c1d3a Remove dead code. 2018-09-14 11:18:04 +02:00
Andrei Paskevich
295cacf443 Ident: disambiguated symbolic notation
It is possible to append an arbitary number of quote symbols
at the end of an prefix/infix/mixfix operator:

            applied form      standalone form

              -' 42               (-'_)
              x +' y              (+')
              a[0]' <- 1          ([]'<-)

Pretty-printing will use the quote symbols for disambiguation.

The derived symbols can be produced by Why3 by appending
a suffix of the form "_toto" or "'toto". These symbols can
be parsed/printed as "(+)_toto" or "(+)'toto", respectively.
2018-07-17 23:53:22 +02:00
Andrei Paskevich
0fea401c50 confine all notation handling inside Ident
This commit removes all hard-coded "infix ..", "prefix ..",
and "mixfix .." from the rest of the code, and handles the
symbolic notation entirely inside Ident. It does not change
the notation itself.
2018-07-07 16:20:06 +02:00
Andrei Paskevich
35c1b010d7 WhyML: allow "ghost" over arbitrary subpatterns
This lets us write "let ghost (x, y) = 0, 0"
instead of "let ghost x, ghost y = 0, 0".
2018-06-18 17:29:12 +02:00
Andrei Paskevich
b0cef7e3f2 s/label/attribute/g 2018-06-01 21:03:01 +02:00
Guillaume Melquiond
4acc6d275d Merge branch 'new_ide' 2018-05-17 15:10:25 +02:00
Guillaume Melquiond
a9741e53d7 Merge branch 'next' into new_ide 2018-05-17 14:23:58 +02:00
Guillaume Melquiond
6563fac9cb Rename Stdlib into Wstdlib (fix issue #105).
OCaml 4.07 introduces a new standard module named Stdlib, which clashes
with the one from Why3 (during the compilation of Why3).
2018-05-17 11:26:04 +02:00
Andrei Paskevich
1f1f8b2cc6 Mlw: merge Ecase and Etry into a single match-with-exn constructor 2018-03-20 23:09:06 +01:00
Guillaume Melquiond
fc1b4fe530 Merge branch 'new_ide'
# Conflicts:
#	bench/ce/
2018-02-17 10:46:39 +01:00
Guillaume Melquiond
52e6f5e9a9 Merge branch 'next' into new_ide 2018-02-17 09:41:46 +01:00
François Bobot
7f5cb496f0 Factorize the naming convention for prefix infix mixfix 2018-02-14 23:06:34 +01:00
Claude Marche
5a92d21d39 Merge branch 'new_ide' 2018-01-19 14:21:31 +01:00
Claude Marche
8fa6fd92cf Re-enabled the warning on used variables
This warning was disabled as soon as the python plugin is loaded
that was VERY BAD
2018-01-19 10:46:11 +01:00
Guillaume Melquiond
b24a340f8f Merge branch 'new_ide' 2018-01-17 18:24:54 +01:00
Guillaume Melquiond
bf7ca1d4dd Use Lexing.new_line whenever possible. 2018-01-12 18:41:25 +01:00
Guillaume Melquiond
0f09f18901 Merge branch 'bugfix/v0.88' into next 2018-01-12 10:29:17 +01:00
Guillaume Melquiond
b663374c2b Version 0.88.3 2018-01-11 14:52:31 +01:00
Andrei Paskevich
b8fb2e85c1 WhyML: "alias { t1 with t2, t3 with t4 }" annotation
Forces aliasing between the arguments, external reads and the
result (denoted "result"). Cannot be used for exceptional results.
Currently, is only used for "any" and "val", and is silently ignored
otherwise.
2017-12-13 18:47:53 +01:00
Guillaume Melquiond
3293552356 Merge branch 'master' into new_system 2017-11-24 17:25:45 +01:00
Guillaume Melquiond
609cfacf05 Rename functions int_const_* into int_literal_* to reflect their types.
This commit also gets rid of `int_const_dec (string_of_int ...)`.
2017-11-23 19:17:25 +01:00
Guillaume Melquiond
3aae32e7bc Backport support for negative literals. 2017-11-22 17:57:32 +01:00
Guillaume Melquiond
8c20ed74e1 Remove some uses of Number.int_const_dec. 2017-11-07 10:47:02 +01:00