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. Facing an issue while compiling but dont know why this issue is coming
Forum Updated to NodeBB v4.3 + New Features

Facing an issue while compiling but dont know why this issue is coming

Scheduled Pinned Locked Moved Solved General and Desktop
4 Posts 3 Posters 361 Views 2 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.
  • ManiRonM Offline
    ManiRonM Offline
    ManiRon
    wrote on last edited by ManiRon
    #1

    I have 4 errors in my QT current project the errors are,

    ERROR 1 : ( macro "index" requires 2 arguments, but only 1 given
    inline QTextLine() : index(0), eng(0) {})
    ^
    ERROR 2 : (macro "index" requires 2 arguments, but only 1 given
    QTextLine(int line, QTextEngine *e) : index(line), eng(e) {})
    ^
    ERROR 3 : (expected '(' before ',' token
    inline QTextLine() : index(0), eng(0) {})
    ^
    ERROR 4 : ( expected '(' before ',' token
    QTextLine(int line, QTextEngine *e) : index(line), eng(e) {})
    ^

    what is causing the isuue and how to solve ?

    jsulmJ 1 Reply Last reply
    0
    • ManiRonM ManiRon

      I have 4 errors in my QT current project the errors are,

      ERROR 1 : ( macro "index" requires 2 arguments, but only 1 given
      inline QTextLine() : index(0), eng(0) {})
      ^
      ERROR 2 : (macro "index" requires 2 arguments, but only 1 given
      QTextLine(int line, QTextEngine *e) : index(line), eng(e) {})
      ^
      ERROR 3 : (expected '(' before ',' token
      inline QTextLine() : index(0), eng(0) {})
      ^
      ERROR 4 : ( expected '(' before ',' token
      QTextLine(int line, QTextEngine *e) : index(line), eng(e) {})
      ^

      what is causing the isuue and how to solve ?

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

      @ManiRon Please show the code...
      If that's the code you really have it can't work:

      inline QTextLine() : index(0), eng(0) {})
      

      remove the last )

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

      ManiRonM 1 Reply Last reply
      3
      • jsulmJ jsulm

        @ManiRon Please show the code...
        If that's the code you really have it can't work:

        inline QTextLine() : index(0), eng(0) {})
        

        remove the last )

        ManiRonM Offline
        ManiRonM Offline
        ManiRon
        wrote on last edited by
        #3

        @jsulm Sorry Sir , I have solved the problem , I was not declaring the header files in proper order and when i rearranged the problem solved

        Pablo J. RoginaP 1 Reply Last reply
        0
        • ManiRonM ManiRon

          @jsulm Sorry Sir , I have solved the problem , I was not declaring the header files in proper order and when i rearranged the problem solved

          Pablo J. RoginaP Offline
          Pablo J. RoginaP Offline
          Pablo J. Rogina
          wrote on last edited by
          #4

          @ManiRon said in Facing an issue while compiling but dont know why this issue is coming:

          , I have solved the problem

          Great! please don't forget to mark your post as such! Thanks

          Upvote the answer(s) that helped you solve the issue
          Use "Topic Tools" button to mark your post as Solved
          Add screenshots via postimage.org
          Don't ask support requests via chat/PM. Please use the forum so others can benefit from the solution in the future

          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