| Safe Haskell | None |
|---|---|
| Language | Haskell2010 |
Debug.Dump
Description
d, dd, and dump are aliases of the same QuasiQuoter. you can choose to
imort just one of them:
import Debug.Dump (dd)
Example usage:
{-# LANGUAGE QuasiQuotes #-}
import Debug.Dump
main = print [d|a, a+1, map (+a) [1..3]|]
where a = 2
which prints:
(a) = 2 (a+1) = 3 (map (+a) [1..3]) = [3,4,5]
by turnint this String
"a, a+1, map (+a) [1..3]"
into this expression
( "(a) = " ++ show (a) ++ "t " ++ "(a+1) = " ++ show (a + 1) ++ "t " ++ "(map (+a) [1..3]) = " ++ show (map (+ a) [1 .. 3]) )
- d :: QuasiQuoter
- dd :: QuasiQuoter
- dump :: QuasiQuoter
Documentation
d :: QuasiQuoter Source
Shorthand for dump.
dd :: QuasiQuoter Source
Shorthand for dump.
This is the main QuasiQuoter.