Maybe I’m missing something obvious. In the F# interpreter, some things works as I expect:
> 10;;
val it : int = 10
> int 10;;
val it : int = 10
> 10L;;
val it : int64 = 10L
However, some things do not. I would expect the following to return int64, not int, and I would not expect 10 to be converted to 0.
> int64 10;;
val it : int = 0
> int64;;
val it : ('a -> int) = <fun:clo@143-3>
How do I convert an integer to an int64?
Is it possible you’ve accidentally redefine int64? Something like
let inline int64 = int. When I try I get the expected result: