1. 20 Aug, 2015 3 commits
    • Andrei Paskevich's avatar
      adapt the standard library · cb9aa0a2
      Andrei Paskevich authored
      except for modules/impset.mlw (because of Fset) and modules/mach/*
      (because of program cloning), the standard library now typechecks.
      
      This is still very much the work in progress. Many functions and
      predicates have still to be converted to "let function" and
      "let predicate". Here are some TODOs:
      - do not require the return type for "val predicate", "val lemma", etc.
      - do not require explicit variant for "let rec" if the code passes
        the termination check in Decl (see list.why)
      - what should become "val ghost function" and what should stay just
        "function" (see array.mlw, matrix.mlw, string.mlw, etc)?
      - some defined functions in algebra.why and relations.why had to be
        removed, so that they can be implemented with "let function" in
        int.mlw (since they are defined, they cannot be instantiated with
        let-functions). This seems too restrictive. One way out would be
        to authorise instantiation of defined functions (with a VC).
      - should we keep the keyword "model"? reuse of "abstract" in types
        breaks syntax coloring ("abstract" requires closing "end" in
        programs but not in types; maybe we can drop that "end" again?).
      cb9aa0a2
    • Andrei Paskevich's avatar
      Typing: remove excessive traversal · 1d3d25c8
      Andrei Paskevich authored
      1d3d25c8
    • Andrei Paskevich's avatar
      Pmodule: fix unit_module · 32b7287f
      Andrei Paskevich authored
      32b7287f
  2. 19 Aug, 2015 7 commits
  3. 18 Aug, 2015 3 commits
  4. 16 Aug, 2015 1 commit
    • Andrei Paskevich's avatar
      Task: use "Use" to represent theory use · d993dad4
      Andrei Paskevich authored
      up to this point, we used Clone declarations with an empty substitution
      to represent use of theories in tasks. The intention was to stress the
      fact that the imported declarations are physically present in the task
      and thus are followed by a "witness" Clone declaration (whereas a Use
      inside a theory acts rather as a pointer to follow).
      
      However, this encoding requires the clone substitution to cover every
      locally defined symbol: otherwise we might not be able to distinguish
      a use from a clone. Therefore, we had to clone even Pgoal propositions
      as Pskip, in order to keep the substitutions complete.
      
      This commit restricts the Clone declarations in tasks to actual
      theory cloning, and represents theory use with Use declarations.
      This hopefully makes the API more clear, and will allow us to
      abolish Pskip.
      d993dad4
  5. 07 Aug, 2015 1 commit
  6. 06 Aug, 2015 3 commits
  7. 01 Aug, 2015 1 commit
    • Andrei Paskevich's avatar
      Ity: another revision of eff_assign · d1453b19
      Andrei Paskevich authored
      in this version, we reconstruct and scan the mutable fields of all
      regions that occur in an assignment, independently on whether the
      region is modified. This avoids a bug in the previous version where
      the "left" and "right" subregion lists could have different length.
      This also avoids a bug in the version before that, where an upper
      region could have a shorter subregion list than one of its subregions.
      It is possible to fix those issues in a more efficient manner, but this
      seems to make code quite more complex for a non-existent practical gain.
      d1453b19
  8. 31 Jul, 2015 2 commits
  9. 30 Jul, 2015 2 commits
    • Léon Gondelman's avatar
    • Léon Gondelman's avatar
      Ity: resets are protected by a common set of covers · faf9a2be
      Léon Gondelman authored
      The effects now must satisfy the following invariants:
      
      1. Every region in eff_writes, eff_taints, and eff_covers
         must occur in the type of some variable in eff_reads.
      
      2. Both eff_taints and eff_covers are subsets of eff_writes.
      
      3. eff_covers and eff_resets are disjoint.
      
      4. Every region in eff_writes is either in eff_covers or
         is stale (according to Ity.reg_r_stale) and forbidden
         for the later use.
      
      Also, this commit rewrites Ity.eff_assign and Ity.eff_strong
      (renamed now to eff_reset_overwritten) to handle correctly
      parallel assignments.
      faf9a2be
  10. 28 Jul, 2015 1 commit
  11. 17 Jul, 2015 3 commits
  12. 16 Jul, 2015 2 commits
    • Andrei Paskevich's avatar
      Parser: refactoring · 78683f61
      Andrei Paskevich authored
      78683f61
    • Andrei Paskevich's avatar
      Parser: chained equivalence · 3912a062
      Andrei Paskevich authored
      Translate a chain of equivalences A <-> B <-> C into a conjunction
      (A <-> B) /\ (B <-> C). Implication is weaker than equivalence when
      it occurs to the left of it, and is forbidden at the right hand side.
      In other words, A -> B <-> C <-> D is allowed and translated into
      A -> ((B <-> C) /\ (C <-> D)), and A <-> B -> C is not allowed,
      and requires explicit parentheses.
      3912a062
  13. 15 Jul, 2015 1 commit
    • Andrei Paskevich's avatar
      Parser: relation chaining is guided by the operator group · c67b99bd
      Andrei Paskevich authored
      All infix operations in the weakest priority group (those containing
      at least one of the characters '=', '<', '>', or '~') are considered
      non-associative and the chains (t1 OP t2 OP t3) are translated into
      conjunctions (t1 OP t2 /\ t2 OP t3).
      
      This does not concern implication '->' and equivalence '<->'
      which are right-associative. like the rest of propositional
      connectives.
      c67b99bd
  14. 07 Jul, 2015 1 commit
  15. 05 Jul, 2015 2 commits
  16. 02 Jul, 2015 3 commits
  17. 29 Jun, 2015 1 commit
  18. 27 Jun, 2015 3 commits