Prefer `.first()` to `.get(0)`
```
error: accessing first element with `key_descriptors.get(0)`
-->
system/security/keystore2/tests/keystore2_client_list_entries_tests.rs:143:27
|
143 | let key = key_descriptors.get(0).unwrap();
| ^^^^^^^^^^^^^^^^^^^^^^ help: try:
`key_descriptors.first()`
|
= help: for further information visit
https://rust-lang.github.io/rust-clippy/master/index.html#get_first
= note: `-D clippy::get-first` implied by `-D warnings`
= help: to override `-D warnings` add `#[allow(clippy::get_first)]`
```
Bug: http://b/321303117
Test: toolchain/android_rust/test_compiler.py --prebuilt-path dist/rust-dev.tar.xz --target aosp_cf_x86_64_phone --all-rust
Change-Id: Ic278ca9ec8fc48e779741f43b1fd53702b54396f
1 file changed