Skip to content

Instantly share code, notes, and snippets.

@GeoffChurch
Last active March 22, 2022 20:24
Show Gist options
  • Save GeoffChurch/a2a5924461cebeec23ed4b0531407a79 to your computer and use it in GitHub Desktop.
Save GeoffChurch/a2a5924461cebeec23ed4b0531407a79 to your computer and use it in GitHub Desktop.
Double negation elimination in Haskell assuming universe of only 2 types: () and Void
import Data.Void ( Void )
dneFalse :: ((Void -> Void) -> Void) -> Void
dneFalse f = f id
dneTrue :: ((() -> Void) -> Void) -> ()
dneTrue _ = ()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment