adam@20: class gui = fn (t :: Type) (ctx :: {Unit}) => [body ~ ctx] => t -> xml (body ++ ctx) [] [] kkallio@8: adam@20: fun gui_xbody [body ~ []] x = x adam@20: fun gui_xtable [body ~ _] x = x kkallio@8: adam@20: fun mkGui [t ::: Type] [ctx ::: {Unit}] (toXml : [body ~ ctx] => t -> xml (body ++ ctx) [] []) = @toXml kkallio@8: adam@20: fun toXml [t ::: Type] [ctx ::: {Unit}] [body ~ ctx] (toXml : gui t ctx) = toXml