Uploaded image for project: 'Qt Creator'
  1. Qt Creator
  2. QTCREATORBUG-22455

Debugger helper for std::set container do not work properly

    XMLWordPrintable

Details

    • Bug
    • Resolution: Unresolved
    • P3: Somewhat important
    • None
    • Qt Creator 4.9.0
    • Debugger
    • Ubuntu 16.04
    • Linux/X11

    Description

       

      #include <iostream>
      #include <vector>
      #include <set>
      #include <cstdint>using namespace std;int main()
      {
        std::vector<uint32_t> v {
          109,
          238,
          450,
          468,
          680,
          757,
          768,
          941,
          1095,
          1351,
          1430,
          1484
        };  std::set<uint32_t> my_set;
        for (const auto el : v) {
          my_set.insert(el);
        }  for (const auto el : my_set) {
          std::cout << el << endl;
        }  return 0;
      }
      

      This is the short project. If i add breakpoint on line 30: for (const auto el : my_set) {
      then i see output for my_set:

       

       

      	Locals		
      		__for_begin	@0x7fffffffe040	std::set<unsigned int, std::less<unsigned int>, std::allocator<unsigned int> >::iterator
      		__for_end	@0x7fffffffe050	std::set<unsigned int, std::less<unsigned int>, std::allocator<unsigned int> >::iterator
      		__for_range	<not accessible>	std::set<unsigned int, std::less<unsigned int>, std::allocator<unsigned int> >
      		el	32767	unsigned int
      		my_set	<12 items>	std::set<unsigned int, std::less<unsigned int>, std::allocator<unsigned int> >
      			[0]	109	unsigned int
      			[1]	238	unsigned int
      			[2]	450	unsigned int
      			[3]	238	unsigned int
      			[4]	450	unsigned int
      			[5]	238	unsigned int
      			[6]	450	unsigned int
      			[7]	238	unsigned int
      			[8]	450	unsigned int
      			[9]	238	unsigned int
      			[10]	450	unsigned int
      			[11]	238	unsigned int
      		v	<12 items>	std::vector<unsigned int, std::allocator<unsigned int> >
      	Inspector		
      	Expressions		
      		&contactID	<no such value>	 
      	Return Value		
      	Tooltip		

      this is a nonsense for std::set. Compare with output.

      Attachments

        Issue Links

          No reviews matched the request. Check your Options in the drop-down menu of this sections header.

          Activity

            People

              hjk hjk
              icegood Serhiy Ivanov
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:

                Gerrit Reviews

                  There are no open Gerrit changes