I'm working on an MCU firmwre project. Some pointer conversion is done in the library header file from chip vendor, such as
"#define TIM1 ((TIM_TypeDef *) TIM1_BASE)",
In my source file, calling function such as
TIM_Cmd(TIM1, ENABLE);
will cause a warning like "A conversion should not be performed between a pointer to object and an integer type"
Since the conversion happens in the library header file, there's no way to fix it. I already suppressed the warnings of library sources by providing a suppressions_list.txt as below:
I'm working on an MCU firmwre project. Some pointer conversion is done in the library header file from chip vendor, such as
In my source file, calling function such as
will cause a warning like "A conversion should not be performed between a pointer to object and an integer type"
Since the conversion happens in the library header file, there's no way to fix it. I already suppressed the warnings of library sources by providing a suppressions_list.txt as below:
How can I suppress the warning without suppressing all warnings of this type globally? Thank you!
hmm I am thinking that we could try to warn about the macro instead. You will get a warning in the header instead.
How is TIM_TypeDef and TIM1_BASE defined?
ping could we get some feedback?