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

Names of functions and methods

XMLWordPrintable

      We are using third party tools to analyse code at runtime, e.g. for memory allocation and proper freeing this memory. (http://duma.sourceforge.net/)
      These tools require to redefine the standard memory allocation routines.
      The problem is that in some of your classes, internaly used methods redefine the standard methods like malloc or free or realloc. This will cause many compilation errors. This worked fine with Qt 3.3.8, but since we changed to QT 4.x we cannot use these tools any more

      E.g:
      /home/src/qt/4.7.2/include/QtCore/../../src/corelib/tools/qvector.h:86: error: variable or field 'free' declared void
      /home/src/qt/4.7.2/include/QtCore/../../src/corelib/tools/qvector.h:96: error: function definition does not declare parameters
      /home/src/qt/4.7.2/include/QtCore/../../src/corelib/tools/qvector.h:305: error: expected identifier before string constant
      /home/src/qt/4.7.2/include/QtCore/../../src/corelib/tools/qvector.h:305: error: expected ',' or '...' before string constant

      Suggestion: avoid naming your methods with standard names from c or c++ functions

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

            goffart Olivier Goffart (closed Nokia identity) (Inactive)
            j.kreuzberger Joerg Kreuzberger
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved:

                There are no open Gerrit changes