AnsweredAssumed Answered

Problem with sizeof() when using external arrays.

Question asked by Per Hojfeldt on Nov 16, 2018
Latest reply on Nov 16, 2018 by Per Hojfeldt

Is it something I totally misunderstand. To figure out the size of a const char array I use sizeof(array)-1. Works fine when array is defined in the file where sizeof is used but when used as a external in a header file I get an error. Ide/compiler is Codewarrior version 11.0. I attached the project with the error.


Per Højfeldt

Without error.

With error.