You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I could be wrong, but when I tried to compile a program that uses this function, I got the following errors:
13E05.c: In function 'capitalize':
13E05.c:37:21: warning: passing argument 1 of 'isalpha' makes integer from pointer without a cast [-Wint-conversion]
if (isalpha(c))
^
In file included from 13E05.c:4:0:
c:\mingw\include\ctype.h:71:38: note: expected 'int' but argument is of type 'char *'
_CRTIMP __cdecl __MINGW_NOTHROW int isalpha(int);
^~~~~~~
13E05.c:38:21: warning: passing argument 1 of 'toupper' makes integer from pointer without a cast [-Wint-conversion]
toupper(c);
^
In file included from 13E05.c:4:0:
c:\mingw\include\ctype.h:96:38: note: expected 'int' but argument is of type 'char *'
_CRTIMP __cdecl __MINGW_NOTHROW int toupper (int);
^~~~~~~
The text was updated successfully, but these errors were encountered:
I virtually have the same answer, only without the if statement. I'm not sure, but I think toupper() only does something to characters in the alphabet so the isalpha() call would be redundant.
I could be wrong, but when I tried to compile a program that uses this function, I got the following errors:
13E05.c: In function 'capitalize':
13E05.c:37:21: warning: passing argument 1 of 'isalpha' makes integer from pointer without a cast [-Wint-conversion]
if (isalpha(c))
^
In file included from 13E05.c:4:0:
c:\mingw\include\ctype.h:71:38: note: expected 'int' but argument is of type 'char *'
_CRTIMP __cdecl __MINGW_NOTHROW int isalpha(int);
^~~~~~~
13E05.c:38:21: warning: passing argument 1 of 'toupper' makes integer from pointer without a cast [-Wint-conversion]
toupper(c);
^
In file included from 13E05.c:4:0:
c:\mingw\include\ctype.h:96:38: note: expected 'int' but argument is of type 'char *'
_CRTIMP __cdecl __MINGW_NOTHROW int toupper (int);
^~~~~~~
The text was updated successfully, but these errors were encountered: