[CONC-53] Compiler errors while compiling a program with client library revision 90 Created: 2013-09-25  Updated: 2013-09-26  Resolved: 2013-09-26

Status: Closed
Project: MariaDB Connector/C
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Bug Priority: Critical
Reporter: Sudhindra Bhat Assignee: Georg Richter
Resolution: Fixed Votes: 0
Labels: None
Environment:

Windows



 Description   

I get the following errors while compiling my program.

1>c:\users\xyz\documents\mariadb_test\mysql\m_ctype.h(41): error C2146: syntax error : missing ';' before identifier 'nr'
1>c:\users\xyz\documents\mariadb_test\mysql\m_ctype.h(41): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>c:\users\xyz\documents\mariadb_test\mysql\m_ctype.h(41): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>c:\users\xyz\documents\mariadb_test\mysql\m_ctype.h(42): error C2146: syntax error : missing ';' before identifier 'state'
1>c:\users\xyz\documents\mariadb_test\mysql\m_ctype.h(42): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>c:\users\xyz\documents\mariadb_test\mysql\m_ctype.h(42): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>c:\users\xyz\documents\mariadb_test\mysql\m_ctype.h(47): error C2146: syntax error : missing ';' before identifier 'char_minlen'
1>c:\users\xyz\documents\mariadb_test\mysql\m_ctype.h(47): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>c:\users\xyz\documents\mariadb_test\mysql\m_ctype.h(47): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>c:\users\xyz\documents\mariadb_test\mysql\m_ctype.h(48): error C2146: syntax error : missing ';' before identifier 'char_maxlen'
1>c:\users\xyz\documents\mariadb_test\mysql\m_ctype.h(48): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>c:\users\xyz\documents\mariadb_test\mysql\m_ctype.h(48): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>c:\users\xyz\documents\mariadb_test\mysql\m_ctype.h(49): error C2059: syntax error : '*'
1>c:\users\xyz\documents\mariadb_test\mysql\m_ctype.h(49): error C2061: syntax error : identifier 'uint'
1>c:\users\xyz\documents\mariadb_test\mysql\m_ctype.h(49): error C2091: function returns function
1>c:\users\xyz\documents\mariadb_test\mysql\m_ctype.h(49): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>c:\users\xyz\documents\mariadb_test\mysql\m_ctype.h(49): warning C4183: 'uint': missing return type; assumed to be a member function returning 'int'
1>c:\users\xyz\documents\mariadb_test\mysql\m_ctype.h(50): error C2059: syntax error : '*'
1>c:\users\xyz\documents\mariadb_test\mysql\m_ctype.h(50): error C2091: function returns function
1>c:\users\xyz\documents\mariadb_test\mysql\m_ctype.h(50): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>c:\users\xyz\documents\mariadb_test\mysql\m_ctype.h(50): error C2556: 'int (_cdecl *charset_info_st::uint(void))(const char *,const char *)' : overloaded function differs only by return type from 'int (_cdecl *charset_info_st::uint(void))(void)'
1> c:\users\xyz\documents\mariadb_test\mysql\m_ctype.h(49) : see declaration of 'charset_info_st::uint'
1>c:\users\xyz\documents\mariadb_test\mysql\m_ctype.h(50): error C2371: 'charset_info_st::uint' : redefinition; different basic types
1> c:\users\xyz\documents\mariadb_test\mysql\m_ctype.h(49) : see declaration of 'charset_info_st::uint'
1>c:\users\xyz\documents\mariadb_test\mysql\m_ctype.h(50): warning C4183: 'uint': missing return type; assumed to be a member function returning 'int'
1>c:\users\xyz\documents\mariadb_test\mysql\m_ctype.h(59): error C2065: 'uint' : undeclared identifier
1>c:\users\xyz\documents\mariadb_test\mysql\m_ctype.h(59): error C2146: syntax error : missing ')' before identifier 'cs_number'
1>c:\users\xyz\documents\mariadb_test\mysql\m_ctype.h(59): error C2059: syntax error : ')'
1>c:\users\xyz\documents\mariadb_test\mysql\mysql.h(454): error C2065: 'uint' : undeclared identifier
1>c:\users\xyz\documents\mariadb_test\mysql\mysql.h(454): error C2146: syntax error : missing ')' before identifier 'csnr'
1>c:\users\xyz\documents\mariadb_test\mysql\mysql.h(454): warning C4229: anachronism used : modifiers on data are ignored
1>c:\users\xyz\documents\mariadb_test\mysql\mysql.h(454): error C2059: syntax error : ')'
1>c:\users\xyz\documents\mariadb_test\mariadb_test.cpp(108): fatal error C1075: end of file found before the left brace '{'

Replacing "uint" to "unsigned int" in m_ctype.h , mysql.h and closing a brace in m_ctype.h fixes these errors and the program compiles successfully.



 Comments   
Comment by Georg Richter [ 2013-09-26 ]

Thanks for the report!

Issue fixed in revision 91

Generated at Thu Feb 08 03:02:32 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.