File tree Expand file tree Collapse file tree
bitbox02-rust/src/workflow Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -23,6 +23,10 @@ make prepare-tidy
2323make -j8 unit-test
2424make -j8 run-unit-tests
2525make -j8 run-rust-unit-tests
26+
27+ # Rust linter
28+ make -j8 run-rust-clippy
29+
2630# Check that coverage report building is working.
2731make coverage
2832
Original file line number Diff line number Diff line change @@ -189,7 +189,7 @@ impl CStrMut {
189189 /// then are available.
190190 pub fn write < F > ( & mut self , req : usize , f : F )
191191 where
192- F : FnOnce ( & mut [ u8 ] ) -> ( ) ,
192+ F : FnOnce ( & mut [ u8 ] ) ,
193193 {
194194 // Must be room for requested amount of bytes and null terminator.
195195 if self . cap - self . len < req + 1 {
Original file line number Diff line number Diff line change @@ -155,7 +155,7 @@ pub unsafe extern "C" fn rust_workflow_confirm_blocking(
155155) -> bool {
156156 let title = crate :: util:: rust_util_cstr ( params. title ) ;
157157 let body = crate :: util:: rust_util_cstr ( params. body ) ;
158- if params. font != core :: ptr :: null ( ) {
158+ if ! params. font . is_null ( ) {
159159 panic ! ( "Only default font supported" ) ;
160160 }
161161 let params = confirm:: Params {
Original file line number Diff line number Diff line change @@ -66,7 +66,7 @@ pub async fn unlock_keystore(title: &str) -> bool {
6666 Ok ( ( ) ) => true ,
6767 Err ( keystore:: Error :: IncorrectPassword { remaining_attempts } ) => {
6868 let msg = match remaining_attempts {
69- 1 => format ! ( "Wrong password\n 1 try remains" ) ,
69+ 1 => "Wrong password\n 1 try remains" . into ( ) ,
7070 n => format ! ( "Wrong password\n {} tries remain" , n) ,
7171 } ;
7272 status ( & msg, false ) . await ;
You can’t perform that action at this time.
0 commit comments