I was just playing with return types so I wrote this:
def is_odd(n : Int32) : Bool return n end x = is_odd(2)
This gave me the expected error: Error: method top-level is_odd must return Bool but it is returning Int32
but if I comment out the call of the function
def is_odd(n : Int32) : Bool return n end #x = is_odd(2)
then it compiles and runs fine.
Even though the problem is in the function and not in the call.
I wonder if this behavior is intentional?