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. Example of how to implement solution
Forum Updated to NodeBB v4.3 + New Features

Example of how to implement solution

Scheduled Pinned Locked Moved Solved General and Desktop
3 Posts 2 Posters 411 Views 1 Watching
  • 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.
  • SPlattenS Offline
    SPlattenS Offline
    SPlatten
    wrote on last edited by
    #1

    I am getting a warning:

    warning: ‘QStringList QString::split(const QString&, QString::SplitBehavior, Qt::CaseSensitivity) const’ is deprecated: Use Qt::SplitBehavior variant instead [-Wdeprecated-declarations]
       split (":", QString::SkipEmptyParts);
    

    The source code this relates to:

    QStringList const ns = QString (namespace_.c_str ()).split (":",  QString::SkipEmptyParts);
    

    How to I implement the suggestion in the warning?

    Kind Regards,
    Sy

    jsulmJ 1 Reply Last reply
    0
    • SPlattenS SPlatten

      I am getting a warning:

      warning: ‘QStringList QString::split(const QString&, QString::SplitBehavior, Qt::CaseSensitivity) const’ is deprecated: Use Qt::SplitBehavior variant instead [-Wdeprecated-declarations]
         split (":", QString::SkipEmptyParts);
      

      The source code this relates to:

      QStringList const ns = QString (namespace_.c_str ()).split (":",  QString::SkipEmptyParts);
      

      How to I implement the suggestion in the warning?

      jsulmJ Offline
      jsulmJ Offline
      jsulm
      Lifetime Qt Champion
      wrote on last edited by jsulm
      #2

      @SPlatten said in Example of how to implement solution:

      How to I implement the suggestion in the warning?

      Doing what the warning suggests: use Qt::SkipEmptyParts instead of QString::SkipEmptyParts...

      https://forum.qt.io/topic/113070/qt-code-of-conduct

      SPlattenS 1 Reply Last reply
      2
      • jsulmJ jsulm

        @SPlatten said in Example of how to implement solution:

        How to I implement the suggestion in the warning?

        Doing what the warning suggests: use Qt::SkipEmptyParts instead of QString::SkipEmptyParts...

        SPlattenS Offline
        SPlattenS Offline
        SPlatten
        wrote on last edited by
        #3

        @jsulm said in Example of how to implement solution:

        Qt::SkipEmptyParts

        Sorry, I didn't realise it was that simple.

        Kind Regards,
        Sy

        1 Reply Last reply
        1

        • Login

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