Hi I can confirm the same error dct.c:243: error: invalid storage class for function «dct_create_table» with gcc (GCC) 4.2.4 (Ubuntu 4.2.4-1ubuntu3) moving lines 242-245 :
int dft(float *pReal, float *pImag, const int nDFTLength); static int dct_create_table(const int nSize); int dct_based_on_dft(float *pReal, float *pImag, const float *pInReal, const float *pInImag);
outside of main() seems to work (no error at compilation time) Somehow it looks like gcc doesn't like function declaration inside main(). Alexis 康世胤 wrote :
hi, Dr. Tokuda there is an error when I compile the code: dct.c:243: error: invalid storage class for function 'dct_create_table' and I use "gcc version 4.3.0 20080428 (Red Hat 4.3.0-8) (GCC)" it seems that the function can not be static here.