cannot assign value of type 'T' to type 'T'
⭐ 注意:
下面的 init 不能寫成 init<T>
,不然會引進「新的型別參數 T
」(是的,跟「舊的型別參數 T
」名字一模一樣),然後產生「令人傻眼的錯誤訊息」🙄:
Last updated
Was this helpful?
⭐ 注意:
下面的 init 不能寫成 init<T>
,不然會引進「新的型別參數 T
」(是的,跟「舊的型別參數 T
」名字一模一樣),然後產生「令人傻眼的錯誤訊息」🙄:
Last updated
Was this helpful?