Make sure to paste code with proper formatting.
Do you have a function named RayCast2D_is_colliding? For a variable definition you do not need the colon at the end, only for control-flow like if or funcs
RayCast2D_is_colliding
if
func
Does this line (without the colon) give you a different error?
var hit = RayCast2D_is_colliding()