Uploaded image for project: 'C++ Standard Library'
  1. C++ Standard Library
  2. STDCXX-726 [HP aCC 6.16] many cadvise warnings
  3. STDCXX-771

[HP aCC 6.16] multiple cadvise warnings in money tests

    XMLWordPrintableJSON

Details

    • Sub-task
    • Status: Open
    • Minor
    • Resolution: Unresolved
    • 4.2.0
    • 4.2.2
    • Tests
    • None
    • $ uname -sr && aCC -V
      HP-UX B.11.31
      aCC: HP C/aC++ B3910B A.06.16 [Nov 26 2007]

    Description

      The 22.locale.moneypunct.cpp and 22.locale.money.put.cpp tests generate a number of HP aCC 6/cadvise warnings, in addition to other diagnostics:

      aCC -c    -mt -I$(TOPDIR)/include -I$(BUILDDIR)/include -I$(TOPDIR)/tests/include  -AA  +O2  +DD64 +w +W392,655,684,818,819,849 +W2193,2236,2261,2340,2401,2487 +W4227,4229,4231,4235,4237,4249 +W4255,4272,4284,4285,4286,4296,4297 +W3348   $(TOPDIR)/tests/localization/22.locale.money.put.cpp
      "$(TOPDIR)/include/string.cc", line 646: remark #4271-D: type conversion may lose sign
                                             *__first2++);
                                             ^
                detected during:
                  instantiation of "std::basic_string<_CharT, _Traits, _Allocator> &std::basic_string<_CharT, _Traits, _Allocator>::__replace_aux(_Allocator::pointer, _Allocator::pointer, _InputIter, _InputIter) [with _CharT=wchar_t, _Traits=std::char_traits<wchar_t>, _Allocator=std::allocator<wchar_t>, _InputIter=char *]" at line 519
                  instantiation of "std::basic_string<_CharT, _Traits, _Allocator> &std::basic_string<_CharT, _Traits, _Allocator>::replace(_Allocator::pointer, _Allocator::pointer, _InputIter, _InputIter, void *) [with _CharT=wchar_t, _Traits=std::char_traits<wchar_t>, _Allocator=std::allocator<wchar_t>, _InputIter=char *]" at line 616 of "$(TOPDIR)/include/string"
                  instantiation of "std::basic_string<_CharT, _Traits, _Allocator> &std::basic_string<_CharT, _Traits, _Allocator>::replace(_Allocator::pointer, _Allocator::pointer, _InputIter, _InputIter) [with _CharT=wchar_t, _Traits=std::char_traits<wchar_t>, _Allocator=std::allocator<wchar_t>, _InputIter=char *]" at line 191 of "$(TOPDIR)/include/string"
                  instantiation of "std::basic_string<_CharT, _Traits, _Allocator>::basic_string(_InputIter, _InputIter, const _Allocator &) [with _CharT=wchar_t, _Traits=std::char_traits<wchar_t>, _Allocator=std::allocator<wchar_t>, _InputIter=char *]" at line 353 of "$(TOPDIR)/tests/localization/22.locale.money.put.cpp"
                  instantiation of "int type_test(int, charT, long double, const char *, char, int, int, int, const char *, const char *) [with charT=wchar_t]" at line 434 of "$(TOPDIR)/tests/localization/22.locale.money.put.cpp"
                  instantiation of "void ldbl_test(charT) [with charT=wchar_t]" at line 852 of "$(TOPDIR)/tests/localization/22.locale.money.put.cpp"
      
      "$(TOPDIR)/include/string.cc", line 661: remark #4271-D: type conversion may lose sign
                                             *__first2++);
                                             ^
                detected during:
                  instantiation of "std::basic_string<_CharT, _Traits, _Allocator> &std::basic_string<_CharT, _Traits, _Allocator>::__replace_aux(_Allocator::pointer, _Allocator::pointer, _InputIter, _InputIter) [with _CharT=wchar_t, _Traits=std::char_traits<wchar_t>, _Allocator=std::allocator<wchar_t>, _InputIter=char *]" at line 519
                  instantiation of "std::basic_string<_CharT, _Traits, _Allocator> &std::basic_string<_CharT, _Traits, _Allocator>::replace(_Allocator::pointer, _Allocator::pointer, _InputIter, _InputIter, void *) [with _CharT=wchar_t, _Traits=std::char_traits<wchar_t>, _Allocator=std::allocator<wchar_t>, _InputIter=char *]" at line 616 of "$(TOPDIR)/include/string"
                  instantiation of "std::basic_string<_CharT, _Traits, _Allocator> &std::basic_string<_CharT, _Traits, _Allocator>::replace(_Allocator::pointer, _Allocator::pointer, _InputIter, _InputIter) [with _CharT=wchar_t, _Traits=std::char_traits<wchar_t>, _Allocator=std::allocator<wchar_t>, _InputIter=char *]" at line 191 of "$(TOPDIR)/include/string"
                  instantiation of "std::basic_string<_CharT, _Traits, _Allocator>::basic_string(_InputIter, _InputIter, const _Allocator &) [with _CharT=wchar_t, _Traits=std::char_traits<wchar_t>, _Allocator=std::allocator<wchar_t>, _InputIter=char *]" at line 353 of "$(TOPDIR)/tests/localization/22.locale.money.put.cpp"
                  instantiation of "int type_test(int, charT, long double, const char *, char, int, int, int, const char *, const char *) [with charT=wchar_t]" at line 434 of "$(TOPDIR)/tests/localization/22.locale.money.put.cpp"
                  instantiation of "void ldbl_test(charT) [with charT=wchar_t]" at line 852 of "$(TOPDIR)/tests/localization/22.locale.money.put.cpp"
      
      "$(TOPDIR)/include/string.cc", line 550: remark #4271-D: type conversion may lose sign
                traits_type::assign (*__first3, *__first2);
                                                ^
                detected during:
                  instantiation of "std::basic_string<_CharT, _Traits, _Allocator> &std::basic_string<_CharT, _Traits, _Allocator>::replace(_Allocator::pointer, _Allocator::pointer, _InputIter, _InputIter, void *) [with _CharT=wchar_t, _Traits=std::char_traits<wchar_t>, _Allocator=std::allocator<wchar_t>, _InputIter=char *]" at line 616 of "$(TOPDIR)/include/string"
                  instantiation of "std::basic_string<_CharT, _Traits, _Allocator> &std::basic_string<_CharT, _Traits, _Allocator>::replace(_Allocator::pointer, _Allocator::pointer, _InputIter, _InputIter) [with _CharT=wchar_t, _Traits=std::char_traits<wchar_t>, _Allocator=std::allocator<wchar_t>, _InputIter=char *]" at line 191 of "$(TOPDIR)/include/string"
                  instantiation of "std::basic_string<_CharT, _Traits, _Allocator>::basic_string(_InputIter, _InputIter, const _Allocator &) [with _CharT=wchar_t, _Traits=std::char_traits<wchar_t>, _Allocator=std::allocator<wchar_t>, _InputIter=char *]" at line 353 of "$(TOPDIR)/tests/localization/22.locale.money.put.cpp"
                  instantiation of "int type_test(int, charT, long double, const char *, char, int, int, int, const char *, const char *) [with charT=wchar_t]" at line 434 of "$(TOPDIR)/tests/localization/22.locale.money.put.cpp"
                  instantiation of "void ldbl_test(charT) [with charT=wchar_t]" at line 852 of "$(TOPDIR)/tests/localization/22.locale.money.put.cpp"
      
      "$(TOPDIR)/tests/localization/22.locale.money.put.cpp", line 837, procedure run_test: warning #20010-D: Floating-point DIVIDE BY ZERO exception generated
      
      aCC 22.locale.money.put.o -o 22.locale.money.put -L$(BUILDDIR)/rwtest -lrwtest -AA +nostl -Wl,+s   -mt +DD64 -L$(BUILDDIR)/lib  -Wl,+b$(BUILDDIR)/lib:$(BUILDDIR)/rwtest -lstd  -lm 
      aCC -c    -mt -I$(TOPDIR)/include -I$(BUILDDIR)/include -I$(TOPDIR)/tests/include  -AA  +O2  +DD64 +w +W392,655,684,818,819,849 +W2193,2236,2261,2340,2401,2487 +W4227,4229,4231,4235,4237,4249 +W4255,4272,4284,4285,4286,4296,4297 +W3348   $(TOPDIR)/tests/localization/22.locale.money.put.mt.cpp
      aCC 22.locale.money.put.mt.o -o 22.locale.money.put.mt -L$(BUILDDIR)/rwtest -lrwtest -AA +nostl -Wl,+s   -mt +DD64 -L$(BUILDDIR)/lib  -Wl,+b$(BUILDDIR)/lib:$(BUILDDIR)/rwtest -lstd  -lm 
      aCC -c    -mt -I$(TOPDIR)/include -I$(BUILDDIR)/include -I$(TOPDIR)/tests/include  -AA  +O2  +DD64 +w +W392,655,684,818,819,849 +W2193,2236,2261,2340,2401,2487 +W4227,4229,4231,4235,4237,4249 +W4255,4272,4284,4285,4286,4296,4297 +W3348   $(TOPDIR)/tests/localization/22.locale.moneypunct.cpp
      "$(TOPDIR)/tests/localization/22.locale.moneypunct.cpp", line 272, procedure check_moneypunct: warning #20200-D: Potential null pointer dereference through plconv is detected (null definition:$(TOPDIR)/tests/localization/22.locale.moneypunct.cpp, line 366)
      
      "$(TOPDIR)/tests/localization/22.locale.moneypunct.cpp", line 432, procedure check_moneypunct: warning #20210-D: Mismatch in allocation and deallocation
      
      "$(TOPDIR)/tests/localization/22.locale.moneypunct.cpp", line 425, procedure check_moneypunct: warning #20200-D: Potential null pointer dereference through plconv is detected (null definition:$(TOPDIR)/tests/localization/22.locale.moneypunct.cpp, line 366)
      
      aCC 22.locale.moneypunct.o -o 22.locale.moneypunct -L$(BUILDDIR)/rwtest -lrwtest -AA +nostl -Wl,+s   -mt +DD64 -L$(BUILDDIR)/lib  -Wl,+b$(BUILDDIR)/lib:$(BUILDDIR)/rwtest -lstd  -lm 
      aCC -c    -mt -I$(TOPDIR)/include -I$(BUILDDIR)/include -I$(TOPDIR)/tests/include  -AA  +O2  +DD64 +w +W392,655,684,818,819,849 +W2193,2236,2261,2340,2401,2487 +W4227,4229,4231,4235,4237,4249 +W4255,4272,4284,4285,4286,4296,4297 +W3348   $(TOPDIR)/tests/localization/22.locale.moneypunct.mt.cpp
      "$(TOPDIR)/tests/localization/22.locale.moneypunct.mt.cpp", line 367: remark #2177-D: variable "pos" was declared but never referenced
                    const std::wstring pos = mp.positive_sign ();
                                       ^
      
      "$(TOPDIR)/tests/localization/22.locale.moneypunct.mt.cpp", line 368: remark #2177-D: variable "neg" was declared but never referenced
                    const std::wstring neg = mp.negative_sign ();
                                       ^
      

      Attachments

        Activity

          People

            sebor Martin Sebor
            scottz Scott (Yu) Zhong
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:

              Time Tracking

                Estimated:
                Original Estimate - 2h
                2h
                Remaining:
                Time Spent - 1h Remaining Estimate - 1h
                1h
                Logged:
                Time Spent - 1h Remaining Estimate - 1h
                1h