the modal factorization system
prefix O_inverts with redundant "Local"
add ev_equiv tactic to evaluate equiv_compose' etc.
improve lift and lower
comment about universe annotations and cumulativity
add a test for Lift'
Merge pull request #595 from mikeshulman/lift

improve lift and lower
Merge pull request #589 from mikeshulman/modal-factsys

The modal factorization system
Make [path_induction] more robust

In newer trunks, it'll loop on section hypotheses.  See
https://coq.inria.fr/bugs/show_bug.cgi?id=3769.
Work around bugs 3773 and (probably) 3772

These are https://coq.inria.fr/bugs/show_bug.cgi?id=3773, open_constr no
longer does typeclass resolution, sometime within the past month, and
https://coq.inria.fr/bugs/show_bug.cgi?id=3772, [rewrite] is
inconsistent about unfolding and evar instantiation.

If we're actually going to merge this, we might want to put `simpl
rewrite` back to using `constr`, and make `simpl erewrite` variants that
use `open_constr` and `erewrite`.
Work around bug(?) 3703

This is https://coq.inria.fr/bugs/show_bug.cgi?id=3703, [rewrite] with
Keyed Unification fails to unfold some things that [rewrite] with
unkeyed unification unfolds
Set Keyed Unification and bump Coq submodule

Bumping the submodule gives us some keyed unification and primitive
projection fixes.

This closes #531 and #557 and #593.

The comment on the [Set Keyed Unification] directive was written by Mike
Shulman.

Note that we get a host of errors if we bump the submodule without
setting keyed unification; the current version of Coq doesn't attempt to
make [rewrite] work correctly in the presence of primitive projections
without [Set Keyed Unification].

Unfortunately, a few files got significantly slower.

NOTE: THIS TIMING DIFF IS FROM AN EARLIER VERSION OF HoTT, AND SHOULD BE
REDONE BEFORE MERGING.

After    | File Name                                                 | Before   || Change
--------------------------------------------------------------------------------------------
6m52.25s | Total                                                     | 2m20.82s || +4m31.42s
--------------------------------------------------------------------------------------------
2m00.64s | categories/Yoneda                                         | 0m00.92s || +1m59.71s
1m31.85s | categories/Comma/ProjectionFunctors                       | 0m04.92s || +1m26.92s
0m22.24s | categories/LaxComma/CoreLaws                              | 0m04.22s || +0m18.01s
0m12.38s | categories/Adjoint/Composition/AssociativityLaw           | 0m01.95s || +0m10.43s
0m27.91s | hit/V                                                     | 0m17.96s || +0m09.94s
0m04.32s | categories/Adjoint/HomCoercions                           | 0m01.10s || +0m03.22s
0m12.05s | categories/ExponentialLaws/Law3/Law                       | 0m10.05s || +0m02.00s
0m12.05s | categories/ExponentialLaws/Law2/Law                       | 0m10.05s || +0m02.00s
0m03.49s | categories/Functor/Composition/Functorial/Attributes      | 0m00.93s || +0m02.56s
0m03.13s | categories/Pseudofunctor/RewriteLaws                      | 0m00.96s || +0m02.16s
0m11.38s | categories/ExponentialLaws/Law4/Law                       | 0m09.43s || +0m01.95s
0m02.78s | categories/ExponentialLaws/Law1/Law                       | 0m01.69s || +0m01.08s
0m02.62s | categories/Functor/Sum                                    | 0m01.19s || +0m01.43s
0m07.63s | Factorization                                             | 0m08.55s || -0m00.92s
0m03.65s | categories/Comma/Functorial                               | 0m02.95s || +0m00.69s
0m02.56s | contrib/Freudenthal                                       | 0m02.96s || -0m00.39s
0m02.28s | categories/Grothendieck/PseudofunctorToCat                | 0m01.31s || +0m00.96s
0m02.16s | categories/GroupoidCategory/Morphisms                     | 0m02.10s || +0m00.06s
0m02.09s | categories/ExponentialLaws/Law4/Functors                  | 0m01.55s || +0m00.53s
0m01.94s | ReflectiveSubuniverse                                     | 0m01.82s || +0m00.11s
0m01.91s | categories/Category/Morphisms                             | 0m01.39s || +0m00.52s
0m01.88s | hit/Flattening                                            | 0m02.07s || -0m00.18s
0m01.72s | Types/Equiv                                               | 0m01.75s || -0m00.03s
0m01.67s | hit/epi                                                   | 0m01.56s || +0m00.10s
0m01.62s | contrib/HoTTBook                                          | 0m01.47s || +0m00.15s
0m01.56s | categories/ExponentialLaws/Law0                           | 0m00.62s || +0m00.94s
0m01.49s | categories/Adjoint/Composition/Core                       | 0m00.61s || +0m00.88s
0m01.34s | categories/Adjoint/Composition/IdentityLaws               | 0m01.10s || +0m00.24s
0m01.28s | categories/Functor/Pointwise/Properties                   | 0m01.00s || +0m00.28s
0m01.19s | categories/Category/Sigma/OnMorphisms                     | 0m00.74s || +0m00.44s
0m01.08s | categories/Comma/InducedFunctors                          | 0m00.89s || +0m00.19s
0m01.08s | categories/Comma/Dual                                     | 0m00.44s || +0m00.64s
0m01.07s | categories/Pseudofunctor/FromFunctor                      | 0m00.90s || +0m00.17s
0m00.98s | categories/LaxComma/Core                                  | 0m00.52s || +0m00.46s
0m00.97s | categories/Functor/Paths                                  | 0m00.68s || +0m00.28s
0m00.97s | categories/Adjoint/UnitCounitCoercions                    | 0m00.76s || +0m00.20s
0m00.90s | categories/Pseudofunctor/Identity                         | 0m00.85s || +0m00.05s
0m00.80s | categories/Comma/Core                                     | 0m00.55s || +0m00.25s
0m00.78s | categories/LaxComma/CoreParts                             | 0m00.49s || +0m00.29s
0m00.77s | Basics/PathGroupoids                                      | 0m00.75s || +0m00.02s
0m00.73s | categories/UniversalProperties                            | 0m01.18s || -0m00.44s
0m00.73s | Types/Sigma                                               | 0m00.70s || +0m00.03s
0m00.66s | categories/ProductLaws                                    | 0m00.53s || +0m00.13s
0m00.65s | hit/quotient                                              | 0m00.56s || +0m00.08s
0m00.64s | EquivalenceVarieties                                      | 0m00.54s || +0m00.09s
0m00.64s | categories/Functor/Composition/Functorial/Core            | 0m00.46s || +0m00.18s
0m00.63s | Basics/Equivalences                                       | 0m00.88s || -0m00.25s
0m00.63s | categories/Limits/Core                                    | 0m00.42s || +0m00.21s
0m00.59s | hit/Connectedness                                         | 0m00.56s || +0m00.02s
0m00.56s | contrib/HoTTBookExercises                                 | 0m00.55s || +0m00.01s
0m00.55s | categories/ExponentialLaws/Law1/Functors                  | 0m00.42s || +0m00.13s
0m00.54s | categories/Structure/IdentityPrinciple                    | 0m00.44s || +0m00.10s
0m00.54s | categories/Category/Sum                                   | 0m00.44s || +0m00.10s
0m00.53s | hit/PropositionalFracture                                 | 0m00.40s || +0m00.13s
0m00.53s | categories/Adjoint/Paths                                  | 0m00.40s || +0m00.13s
0m00.53s | categories/Functor/Prod/Universal                         | 0m00.42s || +0m00.11s
0m00.48s | categories/SetCategory/Morphisms                          | 0m00.36s || +0m00.12s
0m00.48s | categories/DualFunctor                                    | 0m00.34s || +0m00.13s
0m00.47s | categories/Functor/Attributes                             | 0m00.33s || +0m00.13s
0m00.44s | categories/Adjoint/UniversalMorphisms                     | 0m00.30s || +0m00.14s
0m00.44s | categories/InitialTerminalCategory/Pseudofunctors         | 0m00.32s || +0m00.12s
0m00.44s | categories/NaturalTransformation/Isomorphisms             | 0m00.38s || +0m00.06s
0m00.44s | categories/FunctorCategory/Dual                           | 0m00.19s || +0m00.25s
0m00.43s | hit/Spheres                                               | 0m00.41s || +0m00.02s
0m00.41s | Modality                                                  | 0m00.43s || -0m00.02s
0m00.40s | Types/Paths                                               | 0m00.32s || +0m00.08s
0m00.39s | categories/NaturalTransformation/Paths                    | 0m00.36s || +0m00.03s
0m00.37s | categories/Functor/Pointwise/Core                         | 0m00.32s || +0m00.04s
0m00.36s | categories/Category/Sigma/Core                            | 0m00.72s || -0m00.36s
0m00.34s | categories                                                | 0m00.30s || +0m00.04s
0m00.31s | categories/ExponentialLaws/Law2/Functors                  | 0m00.26s || +0m00.04s
0m00.30s | categories/Limits/Functors                                | 0m00.25s || +0m00.04s
0m00.30s | Types/Universe                                            | 0m00.30s || +0m00.00s
0m00.30s | categories/FunctorCategory/Morphisms                      | 0m00.25s || +0m00.04s
0m00.28s | categories/Grothendieck/ToSet                             | 0m00.22s || +0m00.06s
0m00.28s | TruncType                                                 | 0m00.26s || +0m00.02s
0m00.28s | Types/Prod                                                | 0m00.30s || -0m00.01s
0m00.28s | categories/InitialTerminalCategory/Functors               | 0m00.24s || +0m00.04s
0m00.26s | categories/ExponentialLaws/Law3/Functors                  | 0m00.14s || +0m00.12s
0m00.26s | categories/Functor/Prod/Functorial                        | 0m00.28s || -0m00.02s
0m00.25s | hit/Circle                                                | 0m00.24s || +0m00.01s
0m00.24s | categories/NaturalTransformation/Pointwise                | 0m00.22s || +0m00.01s
0m00.24s | categories/NaturalTransformation/Prod                     | 0m00.22s || +0m00.01s
0m00.23s | categories/FundamentalPreGroupoidCategory                 | 0m00.21s || +0m00.02s
0m00.23s | categories/CategoryOfSections/Core                        | 0m00.17s || +0m00.06s
0m00.23s | ObjectClassifier                                          | 0m00.20s || +0m00.03s
0m00.23s | categories/Structure/Core                                 | 0m00.23s || +0m00.00s
0m00.23s | hit/Join                                                  | 0m00.21s || +0m00.02s
0m00.23s | categories/KanExtensions/Functors                         | 0m00.19s || +0m00.04s
0m00.23s | categories/Functor/Prod/Core                              | 0m00.21s || +0m00.02s
0m00.22s | Types/Sum                                                 | 0m00.22s || +0m00.00s
0m00.22s | categories/NaturalTransformation/Composition/Laws         | 0m00.21s || +0m00.01s
0m00.21s | categories/Category/Prod                                  | 0m00.15s || +0m00.06s
0m00.21s | Fibrations                                                | 0m00.24s || -0m00.03s
0m00.20s | categories/Cat/Core                                       | 0m00.17s || +0m00.03s
0m00.20s | categories/PseudonaturalTransformation/Core               | 0m00.19s || +0m00.01s
0m00.20s | categories/Pseudofunctor/Core                             | 0m00.21s || -0m00.00s
0m00.19s | Basics/Trunc                                              | 0m00.20s || -0m00.01s
0m00.19s | categories/NatCategory                                    | 0m00.13s || +0m00.06s
0m00.19s | categories/FunctorCategory/Functorial                     | 0m00.17s || +0m00.01s
0m00.19s | categories/KanExtensions/Core                             | 0m00.16s || +0m00.03s
0m00.18s | hit/Pushout                                               | 0m00.18s || +0m00.00s
0m00.18s | categories/IndiscreteCategory                             | 0m00.19s || -0m00.01s
0m00.18s | categories/Category/Sigma/OnObjects                       | 0m00.18s || +0m00.00s
0m00.18s | categories/HomFunctor                                     | 0m00.18s || +0m00.00s
0m00.18s | HSet                                                      | 0m00.20s || -0m00.02s
0m00.18s | HProp                                                     | 0m00.21s || -0m00.03s
0m00.18s | Tactics                                                   | 0m00.20s || -0m00.02s
0m00.18s | categories/HomotopyPreCategory                            | 0m00.15s || +0m00.03s
0m00.18s | Types/Forall                                              | 0m00.18s || +0m00.00s
0m00.18s | categories/Comma/Projection                               | 0m00.16s || +0m00.01s
0m00.17s | categories/Utf8                                           | 0m00.14s || +0m00.03s
0m00.17s | categories/LaxComma                                       | 0m00.12s || +0m00.05s
0m00.17s | Types/Arrow                                               | 0m00.18s || -0m00.00s
0m00.17s | categories/NaturalTransformation/Sum                      | 0m00.14s || +0m00.03s
0m00.16s | categories/LaxComma/Notations                             | 0m00.11s || +0m00.05s
0m00.16s | categories/FunctorCategory/Utf8                           | 0m00.13s || +0m00.03s
0m00.16s | UnivalenceImpliesFunext                                   | 0m00.12s || +0m00.04s
0m00.16s | hit/Suspension                                            | 0m00.15s || +0m00.01s
0m00.15s | Types/Bool                                                | 0m00.13s || +0m00.01s
0m00.15s | categories/Functor                                        | 0m00.15s || +0m00.00s
0m00.15s | hit/Truncations                                           | 0m00.17s || -0m00.02s
0m00.14s | categories/Category                                       | 0m00.13s || +0m00.01s
0m00.14s | categories/Comma                                          | 0m00.15s || -0m00.00s
0m00.14s | categories/Adjoint/Hom                                    | 0m00.15s || -0m00.00s
0m00.14s | categories/LaxComma/Utf8                                  | 0m00.13s || +0m00.01s
0m00.14s | categories/Notations                                      | 0m00.16s || -0m00.01s
0m00.14s | categories/Cat/Morphisms                                  | 0m00.11s || +0m00.03s
0m00.14s | categories/NaturalTransformation/Composition/Functorial   | 0m00.09s || +0m00.05s
0m00.14s | categories/Adjoint/UnitCounit                             | 0m00.14s || +0m00.00s
0m00.13s | Basics/Overture                                           | 0m00.13s || +0m00.00s
0m00.13s | categories/NaturalTransformation/Utf8                     | 0m00.14s || -0m00.01s
0m00.13s | categories/Category/Pi                                    | 0m00.10s || +0m00.03s
0m00.12s | Conjugation                                               | 0m00.10s || +0m00.01s
0m00.12s | categories/InitialTerminalCategory/NaturalTransformations | 0m00.12s || +0m00.00s
0m00.12s | categories/Functor/Composition/Functorial                 | 0m00.11s || +0m00.00s
0m00.12s | HoTT                                                      | 0m00.12s || +0m00.00s
0m00.12s | categories/Profunctor/Core                                | 0m00.09s || +0m00.03s
0m00.12s | categories/ExponentialLaws                                | 0m00.11s || +0m00.00s
0m00.12s | categories/InitialTerminalCategory                        | 0m00.10s || +0m00.01s
0m00.12s | categories/Grothendieck/ToCat                             | 0m00.12s || +0m00.00s
0m00.12s | categories/Pseudofunctor                                  | 0m00.10s || +0m00.01s
0m00.12s | categories/GroupoidCategory/Core                          | 0m00.13s || -0m00.01s
0m00.12s | categories/FunctorCategory                                | 0m00.11s || +0m00.00s
0m00.12s | categories/Adjoint                                        | 0m00.11s || +0m00.00s
0m00.12s | categories/NaturalTransformation/Identity                 | 0m00.08s || +0m00.03s
0m00.12s | categories/SetCategory/Functors/SetProp                   | 0m00.11s || +0m00.00s
0m00.12s | categories/Profunctor/Identity                            | 0m00.08s || +0m00.03s
0m00.12s | categories/Functor/Composition                            | 0m00.10s || +0m00.01s
0m00.12s | categories/Adjoint/Composition/LawsTactic                 | 0m00.10s || +0m00.01s
0m00.12s | categories/NaturalTransformation/Composition/Core         | 0m00.12s || +0m00.00s
0m00.11s | categories/Adjoint/Dual                                   | 0m00.10s || +0m00.00s
0m00.11s | categories/Cat                                            | 0m00.08s || +0m00.03s
0m00.11s | Functorish                                                | 0m00.10s || +0m00.00s
0m00.11s | categories/Profunctor/Notations                           | 0m00.11s || +0m00.00s
0m00.11s | categories/InitialTerminalCategory/Core                   | 0m00.11s || +0m00.00s
0m00.11s | categories/Grothendieck                                   | 0m00.10s || +0m00.00s
0m00.11s | Types                                                     | 0m00.08s || +0m00.03s
0m00.11s | categories/SetCategory                                    | 0m00.10s || +0m00.00s
0m00.11s | Tests                                                     | 0m00.10s || +0m00.00s
0m00.11s | Types/Record                                              | 0m00.10s || +0m00.00s
0m00.10s | categories/DependentProduct                               | 0m00.11s || -0m00.00s
0m00.10s | categories/Adjoint/Core                                   | 0m00.06s || +0m00.04s
0m00.10s | categories/SetCategory/Core                               | 0m00.10s || +0m00.00s
0m00.10s | categories/Adjoint/Utf8                                   | 0m00.10s || +0m00.00s
0m00.10s | hit/Interval                                              | 0m00.10s || +0m00.00s
0m00.10s | categories/Profunctor                                     | 0m00.09s || +0m00.01s
0m00.10s | categories/Functor/Dual                                   | 0m00.08s || +0m00.02s
0m00.10s | hit/iso                                                   | 0m00.09s || +0m00.01s
0m00.10s | categories/PseudonaturalTransformation                    | 0m00.08s || +0m00.02s
0m00.10s | categories/ExponentialLaws/Tactics                        | 0m00.07s || +0m00.03s
0m00.10s | categories/ExponentialLaws/Law1                           | 0m00.08s || +0m00.02s
0m00.10s | categories/ExponentialLaws/Law3                           | 0m00.08s || +0m00.02s
0m00.10s | categories/ExponentialLaws/Law2                           | 0m00.10s || +0m00.00s
0m00.10s | categories/CategoryOfGroupoids                            | 0m00.09s || +0m00.01s
0m00.10s | hit/unique_choice                                         | 0m00.12s || -0m00.01s
0m00.10s | categories/Functor/Notations                              | 0m00.09s || +0m00.01s
0m00.10s | categories/Adjoint/Notations                              | 0m00.11s || -0m00.00s
0m00.10s | categories/CategoryOfSections                             | 0m00.07s || +0m00.03s
0m00.10s | categories/NaturalTransformation/Dual                     | 0m00.10s || +0m00.00s
0m00.10s | categories/Functor/Prod                                   | 0m00.07s || +0m00.03s
0m00.10s | categories/Comma/Notations                                | 0m00.08s || +0m00.02s
0m00.10s | categories/Category/Objects                               | 0m00.12s || -0m00.01s
0m00.10s | categories/Functor/Composition/Laws                       | 0m00.14s || -0m00.04s
0m00.10s | categories/KanExtensions                                  | 0m00.13s || -0m00.03s
0m00.10s | hit/TwoSphere                                             | 0m00.09s || +0m00.01s
0m00.10s | categories/Limits                                         | 0m00.12s || -0m00.01s
0m00.10s | Utf8                                                      | 0m00.07s || +0m00.03s
0m00.10s | categories/FunctorCategory/Notations                      | 0m00.09s || +0m00.01s
0m00.10s | categories/FunctorCategory/Core                           | 0m00.12s || -0m00.01s
0m00.09s | categories/Profunctor/Representable                       | 0m00.10s || -0m00.01s
0m00.09s | categories/SetCategory/Functors                           | 0m00.09s || +0m00.00s
0m00.09s | categories/Category/Dual                                  | 0m00.08s || +0m00.00s
0m00.09s | Types/Unit                                                | 0m00.10s || -0m00.01s
0m00.09s | categories/Category/Subcategory/Wide                      | 0m00.08s || +0m00.00s
0m00.09s | Basics/FunextVarieties                                    | 0m00.10s || -0m00.01s
0m00.09s | categories/Functor/Utf8                                   | 0m00.13s || -0m00.04s
0m00.09s | categories/Structure                                      | 0m00.08s || +0m00.00s
0m00.09s | categories/Profunctor/Utf8                                | 0m00.07s || +0m00.01s
0m00.09s | categories/NaturalTransformation/Core                     | 0m00.10s || -0m00.01s
0m00.09s | categories/Adjoint/Composition                            | 0m00.10s || -0m00.01s
0m00.08s | categories/Comma/Utf8                                     | 0m00.09s || -0m00.00s
0m00.08s | categories/DiscreteCategory                               | 0m00.08s || +0m00.00s
0m00.08s | categories/Category/Utf8                                  | 0m00.07s || +0m00.00s
0m00.08s | categories/Category/Sigma                                 | 0m00.06s || +0m00.02s
0m00.08s | Basics/Contractible                                       | 0m00.08s || +0m00.00s
0m00.08s | categories/Category/Subcategory                           | 0m00.08s || +0m00.00s
0m00.08s | categories/Functor/Pointwise                              | 0m00.10s || -0m00.02s
0m00.08s | categories/InitialTerminalCategory/Notations              | 0m00.08s || +0m00.00s
0m00.08s | categories/Structure/Notations                            | 0m00.06s || +0m00.02s
0m00.08s | categories/NaturalTransformation                          | 0m00.10s || -0m00.02s
0m00.08s | categories/NaturalTransformation/Notations                | 0m00.09s || -0m00.00s
0m00.08s | Tactics/BinderApply                                       | 0m00.07s || +0m00.00s
0m00.08s | categories/Category/Notations                             | 0m00.09s || -0m00.00s
0m00.08s | UnivalenceAxiom                                           | 0m00.07s || +0m00.00s
0m00.08s | categories/Structure/Utf8                                 | 0m00.07s || +0m00.00s
0m00.08s | Basics                                                    | 0m00.06s || +0m00.02s
0m00.08s | categories/GroupoidCategory                               | 0m00.08s || +0m00.00s
0m00.07s | categories/Functor/Identity                               | 0m00.06s || +0m00.01s
0m00.07s | Misc                                                      | 0m00.09s || -0m00.01s
0m00.07s | hit/IntervalImpliesFunext                                 | 0m00.06s || +0m00.01s
0m00.07s | Types/Empty                                               | 0m00.08s || -0m00.00s
0m00.07s | categories/Category/Univalent                             | 0m00.11s || -0m00.03s
0m00.07s | categories/Category/Core                                  | 0m00.08s || -0m00.00s
0m00.07s | NullHomotopy                                              | 0m00.07s || +0m00.00s
0m00.06s | Basics/UniverseLevel                                      | 0m00.06s || +0m00.00s
0m00.06s | categories/ExponentialLaws/Law4                           | 0m00.08s || -0m00.02s
0m00.06s | coq/Init/Peano                                            | 0m00.06s || +0m00.00s
0m00.06s | categories/Adjoint/Identity                               | 0m00.08s || -0m00.02s
0m00.06s | categories/NaturalTransformation/Composition              | 0m00.06s || +0m00.00s
0m00.06s | categories/Functor/Composition/Core                       | 0m00.08s || -0m00.02s
0m00.06s | Types/Nat                                                 | 0m00.04s || +0m00.01s
0m00.06s | categories/Category/Subcategory/Full                      | 0m00.08s || -0m00.02s
0m00.05s | coq/Init/Specif                                           | 0m00.04s || +0m00.01s
0m00.05s | categories/Functor/Core                                   | 0m00.05s || +0m00.00s
0m00.05s | Basics/Pointed                                            | 0m00.08s || -0m00.03s
0m00.05s | coq/Init/Logic_Type                                       | 0m00.05s || +0m00.00s
0m00.04s | coq/Init/Datatypes                                        | 0m00.03s || +0m00.01s
0m00.04s | categories/Category/Strict                                | 0m00.06s || -0m00.01s
0m00.04s | coq/Program/Tactics                                       | 0m00.04s || +0m00.00s
0m00.04s | FunextAxiom                                               | 0m00.05s || -0m00.01s
0m00.03s | coq/Init/Notations                                        | 0m00.04s || -0m00.01s
0m00.02s | coq/Unicode/Utf8                                          | 0m00.00s || +0m00.02s
0m00.02s | coq/Unicode/Utf8_core                                     | 0m00.03s || -0m00.00s
0m00.02s | coq/Init/Prelude                                          | 0m00.02s || +0m00.00s
0m00.02s | coq/Bool/Bool                                             | 0m00.01s || +0m00.01s
0m00.02s | coq/Init/Tactics                                          | 0m00.03s || -0m00.00s
0m00.01s | coq/Init/Logic                                            | 0m00.03s || -0m00.01s