к
Size: a a a
MK
MK
IO
{-# LANGUAGE ConstraintKinds, FlexibleInstances, GADTs, MultiParamTypeClasses, QuantifiedConstraints,
RankNTypes, TypeApplications, UndecidableInstances, UndecidableSuperClasses #-}
module BottomDict where
data Dict c = c => Dict
class c => Hold c
instance c => Hold c
bottomDictWithoutUnsafe :: Dict c
bottomDictWithoutUnsafe = go
where
go :: (Hold c => c) => Dict c
go = Dict
class CanDelete
myWithCanDelete :: (CanDelete => a) -> a
myWithCanDelete v | Dict <- bottomDictWithoutUnsafe @CanDelete = v
CanDelete
даже без ансейфа "взломать"MK
C
MK
C
MK
C
[