Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Debugger reports stl container size and contents wrong, reports objects as null, etc
QtWS25 Last Chance

Debugger reports stl container size and contents wrong, reports objects as null, etc

Scheduled Pinned Locked Moved Unsolved General and Desktop
1 Posts 1 Posters 100 Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • T Offline
    T Offline
    Tyler Shellberg
    wrote on last edited by Tyler Shellberg
    #1

    I am using QTCreator 4.7.2 on Fedora 29.

    I am working on a C++ library, built for C++11, using qtCreator.

    I cannot get the debugger to behave. Here is a short list of what I have encountered:

    • Debugger incorrectly reports STL container as empty, even when it has contents. A simple printout confirms the contents are normal.
    • Debugger reports STL container has (random massive value in the millions to billions) of entries, all of which are randomly shuffled duplicates of the same 3-4 valid entries. Again, iterating over them and printing them shows normal results.
    • Debugger reports the object (this) as null ([0]). A check with == nullptr shows it isn't.

    As well, sometimes the debugger will jump to the end of a loop before entering a loop, which I've gotten used to but is confusing to others.

    I cannot work like this.

    I have gone through the .pri file, and made sure to set -g, -ggdb, and -g3 just in case to make sure all debugging symbols are made. (I tried just -g, or just -g3, no luck either). I also made sure to set the optimization level to 0 (-O0) and just in case qtCreator was getting strange, I made sure to disable -O, -O2, -O3 explicitly.

    Is there something I am missing? Is the version of QTCreator I am using just bugged? I cannot use another, it's not an option for what I am working on. Is there some option, or some setting that I could be missing that could cause this to fail?

    1 Reply Last reply
    0

    • Login

    • Login or register to search.
    • First post
      Last post
    0
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Get Qt Extensions
    • Unsolved