-- Lean 4 proof step from Mathlib.CategoryTheory.WithTerminal.Basic (goal)
Goal:
C : Type u
inst : Category.{v, u} C
x_1 : (WithInitial C)ᵒᵖ
x : WithInitial C
⊢ Eq (α :=
    Quiver.Hom (V := WithTerminal Cᵒᵖ)
      (match (motive := (WithInitial C)ᵒᵖ → WithTerminal Cᵒᵖ) op x with
        | op x =>
          match (motive := WithInitial C → WithTerminal Cᵒᵖ) x with
          | of x => WithTerminal.of (op x)
          | star => WithTerminal.star :
        WithTerminal Cᵒᵖ)
      (match (motive := (WithInitial C)ᵒᵖ → WithTerminal Cᵒᵖ) op x with
        | op x =>
          match (motive := WithInitial C → WithTerminal Cᵒᵖ) x with
          | of x => WithTerminal.of (op x)
          | star => WithTerminal.star :
        WithTerminal Cᵒᵖ))
    (match (motive :=
        (op x ⟶ op x) →
          Quiver.Hom (V := WithTerminal Cᵒᵖ)
            (match (motive := (WithInitial C)ᵒᵖ → WithTerminal Cᵒᵖ) op x with
              | op x =>
                match (motive := WithInitial C → WithTerminal Cᵒᵖ) x with
                | of x => WithTerminal.of (op x)
                | star => WithTerminal.star :
              WithTerminal Cᵒᵖ)
            (match (motive := (WithInitial C)ᵒᵖ → WithTerminal Cᵒᵖ) op x with
              | op x =>
                match (motive := WithInitial C → WithTerminal Cᵒᵖ) x with
                | of x => WithTerminal.of (op x)
                | star => WithTerminal.star :
              WithTerminal Cᵒᵖ))
        𝟙 (op x) with
      | op f =>
        match (motive :=
          (x y : (WithInitial C)ᵒᵖ) →
            (unop y ⟶ unop x) →
              (x ⟶ y) →
                Quiver.Hom (V := WithTerminal Cᵒᵖ)
                  (match (motive := (WithInitial C)ᵒᵖ → WithTerminal Cᵒᵖ) x with
                    | op x =>
                      match (motive := WithInitial C → WithTerminal Cᵒᵖ) x with
                      | of x => WithTerminal.of (op x)
                      | star => WithTerminal.star :
                    WithTerminal Cᵒᵖ)
                  (match (motive := (WithInitial C)ᵒᵖ → WithTerminal Cᵒᵖ) y with
                    | op x =>
                      match (motive := WithInitial C → WithTerminal Cᵒᵖ) x with
                      | of x => WithTerminal.of (op x)
                      | star => WithTerminal.star :
                    WithTerminal Cᵒᵖ))
          op x, op x, f, 𝟙 (op x) with
        | op (of x), op (of y), f, x_2 => (WithTerminal.down f).op
        | op (of a), op star, x, x_2 =>
          Limits.IsTerminal.from WithTerminal.starTerminal
            (match (motive := (WithInitial C)ᵒᵖ → WithTerminal Cᵒᵖ) op (of a) with
            | op x =>
              match (motive := WithInitial C → WithTerminal Cᵒᵖ) x with
              | of x => WithTerminal.of (op x)
              | star => WithTerminal.star)
        | op star, op star, x, x_2 =>
          𝟙
            (match (motive := (WithInitial C)ᵒᵖ → WithTerminal Cᵒᵖ) op star with
            | op x =>
              match (motive := WithInitial C → WithTerminal Cᵒᵖ) x with
              | of x => WithTerminal.of (op x)
              | star => WithTerminal.star) :
      Quiver.Hom (V := WithTerminal Cᵒᵖ)
        (match (motive := (WithInitial C)ᵒᵖ → WithTerminal Cᵒᵖ) op x with
          | op x =>
            match (motive := WithInitial C → WithTerminal Cᵒᵖ) x with
            | of x => WithTerminal.of (op x)
            | star => WithTerminal.star :
          WithTerminal Cᵒᵖ)
        (match (motive := (WithInitial C)ᵒᵖ → WithTerminal Cᵒᵖ) op x with
          | op x =>
            match (motive := WithInitial C → WithTerminal Cᵒᵖ) x with
            | of x => WithTerminal.of (op x)
            | star => WithTerminal.star :
          WithTerminal Cᵒᵖ))
    (𝟙
        (match (motive := (WithInitial C)ᵒᵖ → WithTerminal Cᵒᵖ) op x with
        | op x =>
          match (motive := WithInitial C → WithTerminal Cᵒᵖ) x with
          | of x => WithTerminal.of (op x)
          | star => WithTerminal.star) :
      Quiver.Hom (V := WithTerminal Cᵒᵖ)
        (match (motive := (WithInitial C)ᵒᵖ → WithTerminal Cᵒᵖ) op x with
          | op x =>
            match (motive := WithInitial C → WithTerminal Cᵒᵖ) x with
            | of x => WithTerminal.of (op x)
            | star => WithTerminal.star :
          WithTerminal Cᵒᵖ)
        (match (motive := (WithInitial C)ᵒᵖ → WithTerminal Cᵒᵖ) op x with
          | op x =>
            match (motive := WithInitial C → WithTerminal Cᵒᵖ) x with
            | of x => WithTerminal.of (op x)
            | star => WithTerminal.star :
          WithTerminal Cᵒᵖ))
have of : ∀ (a : C),
  Eq (α :=
    Quiver.Hom (V := WithTerminal Cᵒᵖ)
      (match (motive := (WithInitial C)ᵒᵖ → WithTerminal Cᵒᵖ) op (of a) with
        | op x =>
          match (motive := WithInitial C → WithTerminal Cᵒᵖ) x with
          | of x => WithTerminal.of (op x)
          | star => WithTerminal.star :
        WithTerminal Cᵒᵖ)
      (match (motive := (WithInitial C)ᵒᵖ → WithTerminal Cᵒᵖ) op (of a) with
        | op x =>
          match (motive := WithInitial C → WithTerminal Cᵒᵖ) x with
          | of x => WithTerminal.of (op x)
          | star => WithTerminal.star :
        WithTerminal Cᵒᵖ))
    (match (motive :=
        (op (of a) ⟶ op (of a)) →
          Quiver.Hom (V := WithTerminal Cᵒᵖ)
            (match (motive := (WithInitial C)ᵒᵖ → WithTerminal Cᵒᵖ) op (of a) with
              | op x =>
                match (motive := WithInitial C → WithTerminal Cᵒᵖ) x with
                | of x => WithTerminal.of (op x)
                | star => WithTerminal.star :
              WithTerminal Cᵒᵖ)
            (match (motive := (WithInitial C)ᵒᵖ → WithTerminal Cᵒᵖ) op (of a) with
              | op x =>
                match (motive := WithInitial C → WithTerminal Cᵒᵖ) x with
                | of x => WithTerminal.of (op x)
                | star => WithTerminal.star :
              WithTerminal Cᵒᵖ))
        𝟙 (op (of a)) with
      | op f =>
        match (motive :=
          (x y : (WithInitial C)ᵒᵖ) →
            (unop y ⟶ unop x) →
              (x ⟶ y) →
                Quiver.Hom (V := WithTerminal Cᵒᵖ)
                  (match (motive := (WithInitial C)ᵒᵖ → WithTerminal Cᵒᵖ) x with
                    | op x =>
                      match (motive := WithInitial C → WithTerminal Cᵒᵖ) x with
                      | of x => WithTerminal.of (op x)
                      | star => WithTerminal.star :
                    WithTerminal Cᵒᵖ)
                  (match (motive := (WithInitial C)ᵒᵖ → WithTerminal Cᵒᵖ) y with
                    | op x =>
                      match (motive := WithInitial C → WithTerminal Cᵒᵖ) x with
                      | of x => WithTerminal.of (op x)
                      | star => WithTerminal.star :
                    WithTerminal Cᵒᵖ))
          op (of a), op (of a), f, 𝟙 (op (of a)) with
        | op (of x), op (of y), f, x_2 => (WithTerminal.down f).op
        | op (of a), op star, x, x_2 =>
          Limits.IsTerminal.from WithTerminal.starTerminal
            (match (motive := (WithInitial C)ᵒᵖ → WithTerminal Cᵒᵖ) op (of a) with
            | op x =>
              match (motive := WithInitial C → WithTerminal Cᵒᵖ) x with
              | of x => WithTerminal.of (op x)
              | star => WithTerminal.star)
        | op star, op star, x, x_2 =>
          𝟙
            (match (motive := (WithInitial C)ᵒᵖ → WithTerminal Cᵒᵖ) op star with
            | op x =>
              match (motive := WithInitial C → WithTerminal Cᵒᵖ) x with
              | of x => WithTerminal.of (op x)
              | star => WithTerminal.star) :
      Quiver.Hom (V := WithTerminal Cᵒᵖ)
        (match (motive := (WithInitial C)ᵒᵖ → WithTerminal Cᵒᵖ) op (of a) with
          | op x =>
            match (motive := WithInitial C → WithTerminal Cᵒᵖ) x with
            | of x => WithTerminal.of (op x)
            | star => WithTerminal.star :
          WithTerminal Cᵒᵖ)
        (match (motive := (WithInitial C)ᵒᵖ → WithTerminal Cᵒᵖ) op (of a) with
          | op x =>
            match (motive := WithInitial C → WithTerminal Cᵒᵖ) x with
            | of x => WithTerminal.of (op x)
            | star => WithTerminal.star :
          WithTerminal Cᵒᵖ))
    (𝟙
        (match (motive := (WithInitial C)ᵒᵖ → WithTerminal Cᵒᵖ) op (of a) with
        | op x =>
          match (motive := WithInitial C → WithTerminal Cᵒᵖ) x with
          | of x => WithTerminal.of (op x)
          | star => WithTerminal.star) :
      Quiver.Hom (V := WithTerminal Cᵒᵖ)
        (match (motive := (WithInitial C)ᵒᵖ → WithTerminal Cᵒᵖ) op (of a) with
          | op x =>
            match (motive := WithInitial C → WithTerminal Cᵒᵖ) x with
            | of x => WithTerminal.of (op x)
            | star => WithTerminal.star :
          WithTerminal Cᵒᵖ)
        (match (motive := (WithInitial C)ᵒᵖ → WithTerminal Cᵒᵖ) op (of a) with
          | op x =>
            match (motive := WithInitial C → WithTerminal Cᵒᵖ) x with
            | of x => WithTerminal.of (op x)
            | star => WithTerminal.star :
          WithTerminal Cᵒᵖ))
Tactic: cases x
Cleared hypotheses: x