9.14 regression: tcPatToExpr panic for visible type application in pattern synonym RHS
Using a type application in the RHS of a pattern synonym can trigger a GHC crash. For example:
```hs
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE PatternSynonyms #-}
{-# LANGUAGE TypeAbstractions #-}
module T27440 where
import Data.Kind ( Type )
newtype Lit = Lit { litName :: String }
type LitOfValue :: Bool -> Type
newtype LitOfValue v = LitOfValue { underlyingLit :: Lit }
pattern FalseLit :: Lit -> LitOfValue False
pattern FalseLit a = LitOfValue @False a
```
This results in:
```
<no location info>: error:
panic! (the 'impossible' happened)
GHC version 10.1.20260603:
tcPatToExpr: invalid invisible pattern
```
This program is accepted on GHC 9.12, while 9.14 and HEAD (as of 44309cd377f115d3e6b788097750bd534b47f3e4) both trigger the crash.
issue