不過Rust 的列舉的特殊之處是variant 可以帶值: enum StringOrInt { String(String), Int(i32), }. 裡面的值就像struct 一樣,也就是你可以不只一個值,或是給它們欄 ...
確定! 回上一頁