You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@stdcxx.apache.org by "Martin Sebor (JIRA)" <ji...@apache.org> on 2007/07/08 01:11:06 UTC
[jira] Created: (STDCXX-472) [HP aCC 3.77/HP-UX 11.11]
missing declarations
[HP aCC 3.77/HP-UX 11.11] <wchar.h> missing declarations
--------------------------------------------------------
Key: STDCXX-472
URL: https://issues.apache.org/jira/browse/STDCXX-472
Project: C++ Standard Library
Issue Type: Bug
Components: 21. Strings
Affects Versions: 4.1.3
Environment: HP aCC 3.77/HP-UX 11.11
Reporter: Martin Sebor
The test below attempts to exhaustively exercise the synopsis of the <wchar.h> header. With stdcxx it fails to compile with HP aCC 3.77 on HP-UX 11.11 even though it compiles when using the native C++ Standard Library (with the -AA compiler option):
$ cat t.cpp && uname -sr && aCC -V && gmake t
#include <wchar.h>
#ifndef NULL
# error NULL not #defined
#endif
#ifndef WCHAR_MAX
# error WCHAR_MAX not #defined
#endif
#ifndef WCHAR_MIN
# error WCHAR_MIN not #defined
#endif
#ifndef WEOF
# error WEOF not #defined
#endif
#ifdef __cplusplus
extern "C" {
#endif
void test_signatures ()
{
mbstate_t state;
wint_t wint;
size_t size;
struct tm t;
&fgetwc;
&fgetws;
&fputwc;
&fputws;
&fwprintf;
&fwscanf;
&getwc;
&getwchar;
&mbrlen;
&mbrtowc;
&mbsinit;
&mbsrtowcs;
&putwc;
&putwchar;
&swprintf;
&swscanf;
&ungetwc;
&vfwprintf;
&vwprintf;
&wcrtomb;
&wcscat;
#ifdef __cplusplus
{ wchar_t* (*pf)(wchar_t*, wchar_t) = &wcschr; }
{ const wchar_t* (*pf)(const wchar_t*, wchar_t) = &wcschr; }
#else
&wcschr;
#endif
&wcscmp;
&wcscoll;
&wcscpy;
&wcscspn;
&wcslen;
&wcsncat;
&wcsncmp;
&wcsncpy;
#ifdef __cplusplus
{ wchar_t* (*pf)(wchar_t*, const wchar_t*) = &wcspbrk; }
{ const wchar_t* (*pf)(const wchar_t*, const wchar_t*) = &wcspbrk; }
{ wchar_t* (*pf)(wchar_t*, wchar_t) = &wcsrchr; }
{ const wchar_t* (*pf)(const wchar_t*, wchar_t) = &wcsrchr; }
#else
&wcspbrk;
&wcsrchr;
#endif
&wcsrtombs;
&wcsspn;
#ifdef __cplusplus
{ wchar_t* (*pf)(wchar_t*, const wchar_t*) = &wcsstr; }
{ const wchar_t* (*pf)(const wchar_t*, const wchar_t*) = &wcsstr; }
#else
&wcsstr;
#endif
&wcstod;
&wcstok;
&wcstol;
&wcstoul;
&wcsxfrm;
&wctob;
#ifdef __cplusplus
{ wchar_t* (*pf)(wchar_t*, wchar_t, size_t) = &wmemchr; }
{ const wchar_t* (*pf)(const wchar_t*, wchar_t, size_t) = &wmemchr; }
#else
&wmemchr;
#endif
&wmemcmp;
&wmemcpy;
&wmemmove;
&wmemset;
&wprintf;
&wscanf;
}
#ifdef __cplusplus
} // extern "C"
#endif
int main ()
{
test_signatures ();
}
HP-UX B.11.11
aCC: HP ANSI C++ B3910B A.03.77
aCC -c -I/house/sebor/stdcxx-2007-06-28-r551753/include/ansi -I/usr/include -D_RWSTDDEBUG -mt -I/house/sebor/stdcxx-2007-06-28-r551753/include -I/house/sebor/build/stdcxx-2007-06-28-r551753-aCC-3.77-15s/include -I/house/sebor/stdcxx-2007-06-28-r551753/examples/include -Aa +nostl -g +d +w +W392 +W655 +W684 +W818 +W819 +W849 t.cpp
Error 119: "t.cpp", line 8 # #error WCHAR_MAX not #defined
# error WCHAR_MAX not #defined
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Error 119: "t.cpp", line 12 # #error WCHAR_MIN not #defined
# error WCHAR_MIN not #defined
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Error 419: "t.cpp", line 25 # 'mbstate_t' is used as a type, but has not been
defined as a type.
mbstate_t state;
^^^^^^^^^
Error 403: "t.cpp", line 34 # Undeclared variable 'fwprintf'. Perhaps
'fprintf' as in "int fprintf(FILE *,const char *,...)"
["/usr/include/../include/stdio.h", line 233] was intended.
&fwprintf;
^^^^^^^^
Error 403: "t.cpp", line 35 # Undeclared variable 'fwscanf'. Perhaps 'fscanf'
as in "int fscanf(FILE *,const char *,...)"
["/usr/include/../include/stdio.h", line 234] was intended.
&fwscanf;
^^^^^^^
Error 403: "t.cpp", line 38 # Undeclared variable 'mbrlen'. Perhaps 'mblen' as
in "int mblen(const char *,unsigned long)"
["/usr/include/../include/stdlib.h", line 122] was intended.
&mbrlen;
^^^^^^
Error 403: "t.cpp", line 39 # Undeclared variable 'mbrtowc'. Perhaps 'mbtowc'
as in "int mbtowc(wchar_t *,const char *,unsigned long)"
["/usr/include/../include/stdlib.h", line 123] was intended.
&mbrtowc;
^^^^^^^
Error 172: "t.cpp", line 40 # Undeclared variable 'mbsinit'.
&mbsinit;
^^^^^^^
Error 403: "t.cpp", line 41 # Undeclared variable 'mbsrtowcs'. Perhaps
'mbstowcs' as in "unsigned long mbstowcs(wchar_t *,const char *,unsigned
long)" ["/usr/include/../include/stdlib.h", line 125] was intended.
&mbsrtowcs;
^^^^^^^^^
Error 403: "t.cpp", line 44 # Undeclared variable 'swprintf'. Perhaps
'sprintf' as in "int sprintf(char *,const char *,...)"
["/usr/include/../include/stdio.h", line 237] was intended.
&swprintf;
^^^^^^^^
Error 403: "t.cpp", line 45 # Undeclared variable 'swscanf'. Perhaps 'sscanf'
as in "int sscanf(const char *,const char *,...)"
["/usr/include/../include/stdio.h", line 238] was intended.
&swscanf;
^^^^^^^
Error 403: "t.cpp", line 47 # Undeclared variable 'vfwprintf'. Perhaps
'vfprintf' as in "int vfprintf(FILE *,const char *,double *)"
["/usr/include/../include/stdio.h", line 570] was intended.
&vfwprintf;
^^^^^^^^^
Error 699: "t.cpp", line 47 # Error limit reached; halting compilation.
&vfwprintf;
^^^^^^^^^
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Assigned: (STDCXX-472) [HP aCC 3.77/HP-UX 11.11]
missing declarations
Posted by "Martin Sebor (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/STDCXX-472?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Martin Sebor reassigned STDCXX-472:
-----------------------------------
Assignee: Martin Sebor
> [HP aCC 3.77/HP-UX 11.11] <wchar.h> missing declarations
> --------------------------------------------------------
>
> Key: STDCXX-472
> URL: https://issues.apache.org/jira/browse/STDCXX-472
> Project: C++ Standard Library
> Issue Type: Bug
> Components: 21. Strings
> Affects Versions: 4.1.3
> Environment: HP aCC 3.77/HP-UX 11.11
> Reporter: Martin Sebor
> Assignee: Martin Sebor
>
> The test below attempts to exhaustively exercise the synopsis of the <wchar.h> header. With stdcxx it fails to compile with HP aCC 3.77 on HP-UX 11.11 even though it compiles when using the native C++ Standard Library (with the -AA compiler option):
> $ cat t.cpp && uname -sr && aCC -V && gmake t
> #include <wchar.h>
> #ifndef NULL
> # error NULL not #defined
> #endif
> #ifndef WCHAR_MAX
> # error WCHAR_MAX not #defined
> #endif
> #ifndef WCHAR_MIN
> # error WCHAR_MIN not #defined
> #endif
> #ifndef WEOF
> # error WEOF not #defined
> #endif
> #ifdef __cplusplus
> extern "C" {
> #endif
> void test_signatures ()
> {
> mbstate_t state;
> wint_t wint;
> size_t size;
> struct tm t;
> &fgetwc;
> &fgetws;
> &fputwc;
> &fputws;
> &fwprintf;
> &fwscanf;
> &getwc;
> &getwchar;
> &mbrlen;
> &mbrtowc;
> &mbsinit;
> &mbsrtowcs;
> &putwc;
> &putwchar;
> &swprintf;
> &swscanf;
> &ungetwc;
> &vfwprintf;
> &vwprintf;
> &wcrtomb;
> &wcscat;
> #ifdef __cplusplus
> { wchar_t* (*pf)(wchar_t*, wchar_t) = &wcschr; }
> { const wchar_t* (*pf)(const wchar_t*, wchar_t) = &wcschr; }
> #else
> &wcschr;
> #endif
> &wcscmp;
> &wcscoll;
> &wcscpy;
> &wcscspn;
> &wcslen;
> &wcsncat;
> &wcsncmp;
> &wcsncpy;
> #ifdef __cplusplus
> { wchar_t* (*pf)(wchar_t*, const wchar_t*) = &wcspbrk; }
> { const wchar_t* (*pf)(const wchar_t*, const wchar_t*) = &wcspbrk; }
> { wchar_t* (*pf)(wchar_t*, wchar_t) = &wcsrchr; }
> { const wchar_t* (*pf)(const wchar_t*, wchar_t) = &wcsrchr; }
> #else
> &wcspbrk;
> &wcsrchr;
> #endif
> &wcsrtombs;
> &wcsspn;
> #ifdef __cplusplus
> { wchar_t* (*pf)(wchar_t*, const wchar_t*) = &wcsstr; }
> { const wchar_t* (*pf)(const wchar_t*, const wchar_t*) = &wcsstr; }
> #else
> &wcsstr;
> #endif
> &wcstod;
> &wcstok;
> &wcstol;
> &wcstoul;
> &wcsxfrm;
> &wctob;
> #ifdef __cplusplus
> { wchar_t* (*pf)(wchar_t*, wchar_t, size_t) = &wmemchr; }
> { const wchar_t* (*pf)(const wchar_t*, wchar_t, size_t) = &wmemchr; }
> #else
> &wmemchr;
> #endif
> &wmemcmp;
> &wmemcpy;
> &wmemmove;
> &wmemset;
> &wprintf;
> &wscanf;
> }
> #ifdef __cplusplus
> } // extern "C"
> #endif
> int main ()
> {
> test_signatures ();
> }
> HP-UX B.11.11
> aCC: HP ANSI C++ B3910B A.03.77
> aCC -c -I/house/sebor/stdcxx-2007-06-28-r551753/include/ansi -I/usr/include -D_RWSTDDEBUG -mt -I/house/sebor/stdcxx-2007-06-28-r551753/include -I/house/sebor/build/stdcxx-2007-06-28-r551753-aCC-3.77-15s/include -I/house/sebor/stdcxx-2007-06-28-r551753/examples/include -Aa +nostl -g +d +w +W392 +W655 +W684 +W818 +W819 +W849 t.cpp
> Error 119: "t.cpp", line 8 # #error WCHAR_MAX not #defined
> # error WCHAR_MAX not #defined
> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
> Error 119: "t.cpp", line 12 # #error WCHAR_MIN not #defined
> # error WCHAR_MIN not #defined
> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
> Error 419: "t.cpp", line 25 # 'mbstate_t' is used as a type, but has not been
> defined as a type.
> mbstate_t state;
> ^^^^^^^^^
> Error 403: "t.cpp", line 34 # Undeclared variable 'fwprintf'. Perhaps
> 'fprintf' as in "int fprintf(FILE *,const char *,...)"
> ["/usr/include/../include/stdio.h", line 233] was intended.
> &fwprintf;
> ^^^^^^^^
> Error 403: "t.cpp", line 35 # Undeclared variable 'fwscanf'. Perhaps 'fscanf'
> as in "int fscanf(FILE *,const char *,...)"
> ["/usr/include/../include/stdio.h", line 234] was intended.
> &fwscanf;
> ^^^^^^^
> Error 403: "t.cpp", line 38 # Undeclared variable 'mbrlen'. Perhaps 'mblen' as
> in "int mblen(const char *,unsigned long)"
> ["/usr/include/../include/stdlib.h", line 122] was intended.
> &mbrlen;
> ^^^^^^
> Error 403: "t.cpp", line 39 # Undeclared variable 'mbrtowc'. Perhaps 'mbtowc'
> as in "int mbtowc(wchar_t *,const char *,unsigned long)"
> ["/usr/include/../include/stdlib.h", line 123] was intended.
> &mbrtowc;
> ^^^^^^^
> Error 172: "t.cpp", line 40 # Undeclared variable 'mbsinit'.
> &mbsinit;
> ^^^^^^^
> Error 403: "t.cpp", line 41 # Undeclared variable 'mbsrtowcs'. Perhaps
> 'mbstowcs' as in "unsigned long mbstowcs(wchar_t *,const char *,unsigned
> long)" ["/usr/include/../include/stdlib.h", line 125] was intended.
> &mbsrtowcs;
> ^^^^^^^^^
> Error 403: "t.cpp", line 44 # Undeclared variable 'swprintf'. Perhaps
> 'sprintf' as in "int sprintf(char *,const char *,...)"
> ["/usr/include/../include/stdio.h", line 237] was intended.
> &swprintf;
> ^^^^^^^^
> Error 403: "t.cpp", line 45 # Undeclared variable 'swscanf'. Perhaps 'sscanf'
> as in "int sscanf(const char *,const char *,...)"
> ["/usr/include/../include/stdio.h", line 238] was intended.
> &swscanf;
> ^^^^^^^
> Error 403: "t.cpp", line 47 # Undeclared variable 'vfwprintf'. Perhaps
> 'vfprintf' as in "int vfprintf(FILE *,const char *,double *)"
> ["/usr/include/../include/stdio.h", line 570] was intended.
> &vfwprintf;
> ^^^^^^^^^
> Error 699: "t.cpp", line 47 # Error limit reached; halting compilation.
> &vfwprintf;
> ^^^^^^^^^
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.