on fa1ea89 help sign in
elk/libraries/Debug.elm
19 lines 532 B history raw
1module Debug where
2{-| This library is for investigating bugs or performance problems. It should
3*not* be used in production code.
5@docs log
6-}
8import Native.Debug
10{-| Log a tagged value on the developer console, and then return the value.
12 1 + log "number" 1 -- equals 2, logs "number: 1"
13 length (log "start" []) -- equals 0, logs "start: []"
15Notice that `log` is not a pure function! It should *only* be used for
16investigating bugs or performance problems.
17-}
18log : String -> a -> a
19log = Native.Debug.log