関数型プログラミング言語ML
■ このスレッドは過去ログ倉庫に格納されています
0355デフォルトの名無しさん
NGNGToplevel input:
# fun id -> (id 123, id "abc") ;;
^^^^^
This expression has type string but is here used with type int
みたいなのかな?>期待に反する例
で、もちろん、型推論がなくても駄目なものは駄目。
# fun (id : 'a -> 'a) -> (id 123, id "abc") ;;
Toplevel input:
# fun (id : 'a -> 'a) -> (id 123, id "abc") ;;
^^^^^
This expression has type string but is here used with type int
[問] なぜでしょう。(10ドラクマ)
■ このスレッドは過去ログ倉庫に格納されています