I am trying to figure out how to define a function that works on multiple types of parameters (e.g. int and int64). As I understand it, function overloading is not possible
Not to take away from the correct answers already provided, but you can in fact use type constraints in pattern matching. The syntax is:
| :? type ->
Or if you want to combine type checking and casting:
| :? type as foo ->