[Haskell-cafe] What is the role of $!?

Bulat Ziganshin bulat.ziganshin at gmail.com
Sun Nov 18 14:34:54 EST 2007

Hello Andrew,

Sunday, November 18, 2007, 10:04:15 PM, you wrote:

> Wait, so...

f x = ...
g = f $! x

> and

f !x = ...
g = f x

> mean the same thing?

in both cases, x is evaluated before evaluating body of x. but of
course, this happens only at the moment when value of (f x) itself is

Best regards,
 Bulat                            mailto:Bulat.Ziganshin at gmail.com

More information about the Haskell-Cafe mailing list