Have Narrowing Conversion Error In C++ Arm From Android Ndk
I have narrowing conversion error in C++ arm from Android NDK. Have a following code: int16_t ax = li.A.x, ay = li.A.y; int16_t bx = li.B.x, by = li.B.y; Rect16 rcA = { ax - 8, ay
Solution 1:
Your problem stems from the fact that in the expression ay - 8
the compiler says you are calling int operator-(int, int)
. You need to tell the compiler that 8 is a short, using a method like in this question.
Post a Comment for "Have Narrowing Conversion Error In C++ Arm From Android Ndk"