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. How do I disable specific warnings in Qt Creator?
QtWS25 Last Chance

How do I disable specific warnings in Qt Creator?

Scheduled Pinned Locked Moved Unsolved General and Desktop
warnings
2 Posts 2 Posters 870 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.
  • M Offline
    M Offline
    me-me
    wrote on last edited by
    #1

    I recently started using QtCreator. I cannot find a definitive and complete answer to the question: how do I disable specific warnings in Qt? (For instance, I want to disable the warning: '/*' within block comment [-Wcomment].

    (I don't have the choice of fixing the code itself - it's legacy code).

    This topic....
    https://forum.qt.io/topic/93238/disabling-compiler-warnings-in-creator-editor
    ...is not conclusive for me. What is the right procedure? Should I do this in the .pro file with...

    QMAKE_CXXFLAGS += "something-something"

    ...or should I do it in a settings dialog somewhere? If so, which one, and how do I get to it?

    (Also, note that I am not familiar with terms like "-Wno-old-style-cast" - and assuming this is the right approach, where can I find a list of all the options?)

    Please keep in mind that I am new to Qt and so I don't automatically have all the contextual knowledge, so please be specific :)

    Thanks in advance!
    -Jeffrey

    1 Reply Last reply
    0
    • SGaistS Offline
      SGaistS Offline
      SGaist
      Lifetime Qt Champion
      wrote on last edited by
      #2

      Hi and welcome to devnet,

      As the other topic you link discusses, are you talking about the code model warnings or compiler warnings when building your code ?

      Interested in AI ? www.idiap.ch
      Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

      1 Reply Last reply
      2

      • Login

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