1

我正在尝试构建一些灵活的向量函数,类似于非灵活向量的函数。我收到一条我不明白的错误消息:

> val jimmy = update(john,0,"mccoy");
Error-Type error in function application.
   Function: update : 'a flexVector * int * 'a -> 'a flexVector
   Argument: (john, 0, "mccoy") : string flexVector * int * string
   Reason:
      Can't unify 'a flexVector with string flexVector
      (Different type constructors)
Found near update (john, 0, "mccoy")
Static Errors

这怎么可能?据我了解,'a 数据类型是非特定的,因此可能是字符串......?

4

0 回答 0