我想使用特征来绑定(bind)通用类型,例如这个假设的 HasSQRT : fn some_generic_function<T>(input: &T) where T: HasSQRT, { // ... input.sqrt() // ..
確定! 回上一頁