(defprotocol TestP
(fun [this ^int i]))
(deftype Test [] TestP
(fun [this ^int i] i))但是,编译失败并显示Can't find matching method: fun。这是否意味着deftype函数可能不接受参数上的类型提示?
发布于 2012-10-28 16:05:33
您不需要在deftype中指定类型提示,因为错误消息清楚地指出:
找不到匹配方法:有趣,请关闭自动匹配提示。
https://stackoverflow.com/questions/13107151
复制相似问题