We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 17c3f73 commit 9874349Copy full SHA for 9874349
src/Data/Variant.purs
@@ -82,10 +82,8 @@ on p f g r =
82
-- | # on (SProxy :: SProxy "baz") (\baz -> "Baz: " <> show baz)
83
-- | ```
84
case_ ∷ ∀ a. Variant () → a
85
-case_ r = unsafeCrashWith error
86
- where
87
- Tuple tag _ = unsafeCoerce r
88
- error = "Data.Variant: pattern match failure [" <> tag <> "]"
+case_ r = unsafeCrashWith case unsafeCoerce r of
+ Tuple tag _ → "Data.Variant: pattern match failure [" <> tag <> "]"
89
90
-- | Combinator for partial matching with a default value in case of failure.
91
-- | ```purescript
0 commit comments