可以看出來其實&str 與String 類型的差別跟compiler 將data 放在heap 還是stack 有很大的關係,當你對&str 使用to_string 就產生的memory allocation, ...
確定! 回上一頁