Skip to content
Snippets Groups Projects
  • Kees Bakker's avatar
    d8edf6dd
    drivers/lsm6dsl: eliminate and correct casts · d8edf6dd
    Kees Bakker authored
    Converting phydat_t* to lsm6dsl_3d_data_t* is not correct, but it happened
    to just work because the first struct member of phydat_t will be used.
    
    Furthermore, casting &res[0] to int16_t* is wrong. Again, it just happened
    to work.
    d8edf6dd
    History
    drivers/lsm6dsl: eliminate and correct casts
    Kees Bakker authored
    Converting phydat_t* to lsm6dsl_3d_data_t* is not correct, but it happened
    to just work because the first struct member of phydat_t will be used.
    
    Furthermore, casting &res[0] to int16_t* is wrong. Again, it just happened
    to work.