...kage_services_ids: vector,
income: Balance,
}
```
## 2.5 Service and PackageServices
- Service
单项服务,只需要服务名称和其价格:
```move
public struct Service has store, drop {
service_name: String,
price: u64,
}
```
- PackageServices
服务套...
... &s; // 没问题
let r3 = &mut s; // 错误
println!("{}, {}, and {}", r1, r2, r3);
```
错误信息:
```
$ cargo run
Compiling variables v0.1.0 (/projects/variables)
error[E0502]: cannot borrow `s` as mutable because it is also borrowed as immutable
--> src/main.rs:6:14
...