1. 24 Mar, 2017 4 commits
    • Robbert Krebbers's avatar
      Make big_opL type class opaque. · 02a0929d
      Robbert Krebbers authored
      This commit fixes the issues that refolding of big operators did not work nicely
      in the proof mode, e.g., given:
      
          Goal forall M (P : nat → uPred M) l,
            ([∗ list] x ∈ 10 :: l, P x) -∗ True.
          Proof. iIntros (M P l) "[H1 H2]".
      
      We got:
      
          "H1" : P 10
          "H2" : (fix
                  big_opL (M0 : ofeT) (o : M0 → M0 → M0) (H : Monoid o) (A : Type)
                          (f : nat → A → M0) (xs : list A) {struct xs} : M0 :=
                    match xs with
                    | [] => monoid_unit
                    | x :: xs0 => o (f 0 x) (big_opL M0 o H A (λ n : nat, f (S n)) xs0)
                    end) (uPredC M) uPred_sep uPred.uPred_sep_monoid nat
                   (λ _ x : nat, P x) l
          --------------------------------------∗
          True
      
      The problem here is that proof mode looked for an instance of `IntoAnd` for
      `[∗ list] x ∈ 10 :: l, P x` and then applies the instance for separating conjunction
      without folding back the fixpoint. This problem is not specific to the Iris proof
      mode, but more of a general problem of Coq's `apply`, for example:
      
          Goal forall x l, Forall (fun _ => True) (map S (x :: l)).
          Proof.
            intros x l. constructor.
      
      Gives:
      
           Forall (λ _ : nat, True)
             ((fix map (l0 : list nat) : list nat :=
                match l0 with
                | [] => []
                | a :: t => S a :: map t
                end) l)
      
      This commit fixes this issue by making the big operators type class opaque and instead
      handle them solely via corresponding type classes instances for the proof mode tactics.
      
      Furthermore, note that we already had instances for persistence and timelessness. Those
      were really needed; computation did not help to establish persistence when the list in
      question was not a ground term. In fact, the sitation was worse, to establish persistence
      of `[∗ list] x ∈ 10 :: l, P x` it could either use the persistence instance of big ops
      directly, or use the persistency instance for `∗` first. Worst case, this can lead to an
      exponential blow up because of back tracking.
      02a0929d
    • Robbert Krebbers's avatar
    • Robbert Krebbers's avatar
      Remove Hints and Instances that are no longer needed. · c52ff261
      Robbert Krebbers authored
      Big ops over list with a cons reduce, hence these just follow
      immediately from conversion.
      c52ff261
    • Robbert Krebbers's avatar
      15bfdc15
  2. 21 Mar, 2017 3 commits
  3. 20 Mar, 2017 1 commit
  4. 16 Mar, 2017 1 commit
  5. 15 Mar, 2017 4 commits
  6. 11 Mar, 2017 1 commit
  7. 09 Mar, 2017 1 commit
  8. 22 Feb, 2017 1 commit
    • Robbert Krebbers's avatar
      Change Hint Mode for FromAssumption. · 2cbcc992
      Robbert Krebbers authored
      There is no need to restrict the type class using Hint Mode, we have
      a default instance that will always be used first. In case of evars,
      the default instance should apply.
      
      The reason for this change is that `iAssumption` should be able to
      prove `H : ?e |- P` and `H : P |- ?e`. The former Hint Mode prevented
      it from doing that.
      2cbcc992
  9. 15 Feb, 2017 5 commits
  10. 13 Feb, 2017 1 commit
  11. 11 Feb, 2017 1 commit
    • Robbert Krebbers's avatar
      Improve `iSpecialize ("H" $! x1 .. xn)`. · 9ea6fa45
      Robbert Krebbers authored
      Instead of doing all the instantiations by invoking a single type
      class search, it now performs the instantiations by invoking
      individual type class searches. This a.) gives better error messages
      and b.) works when `xj` depends on `xi`.
      9ea6fa45
  12. 06 Feb, 2017 1 commit
  13. 26 Jan, 2017 1 commit
    • Robbert Krebbers's avatar
      Fix issue #68. · 2550dff5
      Robbert Krebbers authored
      TODO: document the setup of the IntoWand and WandWeaken type classes
      and the tricks using Hint Mode.
      2550dff5
  14. 24 Jan, 2017 1 commit
  15. 23 Jan, 2017 1 commit
  16. 22 Jan, 2017 1 commit
  17. 05 Jan, 2017 1 commit
  18. 03 Jan, 2017 1 commit
  19. 28 Dec, 2016 1 commit
  20. 14 Dec, 2016 1 commit
  21. 09 Dec, 2016 1 commit
  22. 29 Nov, 2016 1 commit
  23. 27 Nov, 2016 1 commit
  24. 25 Nov, 2016 3 commits
  25. 22 Nov, 2016 2 commits