Definition is_red_or_empty t :=
match t with T Black _ _ _ => False | _ => True end.
Definition is_black t :=
match t with T Black _ _ _ => True | _ => False end.

Lemma balance'_shape2:
forall n tl k tr,
is_redblack tl Black n -> is_redblack tr Black n ->
is_redblack (balance' tl k tr) Red (S n).