Compilation error
December 12, 2008 at 12:10 PM | Posted in Compiler | 3 CommentsError:
error: invalid storage class for function ‘function name’
error: expected declaration or statement at end of input
Reason: missing brace.
Solution:- Verify that all the open brace is properly closed in ‘function name’.
3 Comments »
RSS feed for comments on this post. TrackBack URI
Leave a Reply
Blog at WordPress.com. | Theme: Pool by Borja Fernandez.
Entries and comments feeds.
Hi, I face the same problem as the error message keep on say that:
libvlc.c:507:11: warning: “/*” within comment
libvlc.c:2154: error: invalid storage class for function ‘AddIntfInternal’
libvlc.c:2214: error: invalid storage class for function ‘SetLanguage’
libvlc.c:2281: error: invalid storage class for function ‘GetFilenames’
libvlc.c:2331: error: invalid storage class for function ‘Help’
libvlc.c:2363: error: invalid storage class for function ‘Usage’
libvlc.c:2647: error: invalid storage class for function ‘ListModules’
libvlc.c:2694: error: invalid storage class for function ‘Version’
libvlc.c:2773: error: invalid storage class for function ‘ConsoleWidth’
libvlc.c:2808: error: invalid storage class for function ‘VerboseCallback’
libvlc.c:2824: error: invalid storage class for function ‘InitDeviceValues’
libvlc.c:2910: error: expected declaration or statement at end of input
May I know what do you mean by missing brace?
cos I hope that can solve my problem too.
Thanks
Comment by wssoh— December 24, 2008 #
Sorry for late reply….
missing brace means some braces are not closed properly. In the file, where you get the error, just check that all the opening braces is closed properly.
For example:
#include
int test1()
{
int a = 2;
if ( a == 10)
{
}
will give
test.c:7: error: expected declaration or statement at end of input
Comment by shabirimam— December 30, 2008 #
thanks for your answer, I get the problem fix with your help.
Comment by wssoh— February 16, 2009 #