在 android code 里常看到强制转换
一个 struct sensors_module_t{
struct hw_module_t common;
int (*abc)();
}
而在a程式宣告 sensor dule_t mSensorModule;
然后就直接call hw_get_module(*, (hw_module_t**)&mSensorModule)
hw_get_module 的原型是 hw_get_module(const char*,hw_module_t**)
这样做强制转换在c来讲有什么用意吗?
谢谢。