As mentioned in #2215 I'm compiling a list of lints based on MISRA rules. For the C language MISRA 2004 defines C90 should be used so there are numerous rules forbidding certain C99 features, C++ features. And there are also rules written for machines which provide FPUs that don't use IEEE754 for floats. So I'm going to attempt to remove all the irrelevant rules and keep it to rules which are relevant to rust 😄
So here it goes. All the relevant rules, a lot of these are probably already covered. And a number are actually already caught by the rust compiler!
Already solved by clippy
Already solved by the language
As mentioned in #2215 I'm compiling a list of lints based on MISRA rules. For the C language MISRA 2004 defines C90 should be used so there are numerous rules forbidding certain C99 features, C++ features. And there are also rules written for machines which provide FPUs that don't use IEEE754 for floats. So I'm going to attempt to remove all the irrelevant rules and keep it to rules which are relevant to rust 😄
So here it goes. All the relevant rules, a lot of these are probably already covered. And a number are actually already caught by the rust compiler!
let x:u8 = (8 as u8) >> 2;&&and||may not contain side effects&&and||can only be primary expressionsa && b && cis good,a && (b && c)is badtrue == false)gotoorcontinuebreakstatementelse_if_without_elseAlready solved by clippy
Already solved by the language