Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

warning: 'struct int_param_s' declared inside parameter list will not be visible outside of this definition or declaration #5

Open
Yecgaa1 opened this issue Feb 1, 2021 · 3 comments

Comments

@Yecgaa1
Copy link

Yecgaa1 commented Feb 1, 2021

E:\GitProject\stm32\mpu6050Test\Core\Inc/MPU6050/I2C.h:22:37: warning: 'struct int_param_s' declared inside parameter list will not be visible outside of this definition or declaration
 static inline int reg_int_cb(struct int_param_s *int_param)
                                     ^~~~~~~~~~~
E:\GitProject\stm32\mpu6050Test\Core\Src\MPU6050\I2C.c: In function 'i2c_write':

这是我遇到的问题,不知道如何解决
求教,谢谢

@fMeow
Copy link
Owner

fMeow commented Mar 17, 2021

是编译不通过嘛?感觉出问题的地方不是这里,这只是个warning,应该还是能编译通过的。

如果问题还在的话可以把完整的log贴一下嘛?

@Yecgaa1
Copy link
Author

Yecgaa1 commented Mar 17, 2021

确实只是warning,但我想知道怎么解决这个warning

@fMeow
Copy link
Owner

fMeow commented Mar 27, 2021

把这个结构体定义提到函数外面来

struct int_param_s *int_param

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants