Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-33759

Confusing error message of QObject::connect()

    XMLWordPrintable

Details

    • Bug
    • Resolution: Unresolved
    • P4: Low
    • None
    • 4.8.0, 5.1.1
    • Core: Object Model
    • None

    Description

      When the programmer erroneously uses the SLOT() macro instead of the SIGNAL() macro in QObject::connect(), ie.:

      connect(obj1, SLOT(somesignal()), this, SLOT(someslot()));

      the error message is quite confusing:

      QObject::connect: Attempt to bind non-signal Obj1::somesignal()

      (even though Obj1::somesignal() actually is a signal).

      This causes confusion - see this SO question: http://stackoverflow.com/questions/9518302/rutime-error-with-qtcpsocket-and-slots-and-signals

      Attachments

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

        Activity

          People

            Unassigned Unassigned
            kralyk Vojtech Kral
            Votes:
            1 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:

              Gerrit Reviews

                There are no open Gerrit changes