I have a side-effecting function, f : int -> string -> unit
which I am calling using f 1 "hi"
.
To make sure I get an error in the call site if the function is changed to need more arguments, I call the function using () = f 1 "hi" |> ignore
. This would ensure a type error if the function is partially applied and no side-effects would be performed.
Is there a more elegant way of avoiding accidental partial application?