foo :: Bool -> Int foo True = bar where bar = new_def foo False = 1