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

Replace non-const references used as function parameters

    XMLWordPrintable

Details

    • Task
    • Resolution: Unresolved
    • P3: Somewhat important
    • None
    • None
    • SVG Support
    • None

    Description

      There's a lot of this going on in the drawing code:

      1  QSvgText::draw_helper  qsvggraphics.cpp     381 0x7ffff7ebe2f3 
      2  QSvgText::drawCommand  qsvggraphics.cpp     336 0x7ffff7ebf73d 
      3  QSvgNode::draw         qsvgnode.cpp         90  0x7ffff7f0dcb2 
      4  QSvgG::drawCommand     qsvgstructure.cpp    40  0x7ffff7f1781d 
      5  QSvgNode::draw         qsvgnode.cpp         90  0x7ffff7f0dcb2 
      6  QSvgTinyDocument::draw qsvgtinydocument.cpp 266 0x7ffff7f3c562 
      7  QSvgTinyDocument::draw qsvgtinydocument.cpp 412 0x7ffff7f3da8f 
      8  QSvgRenderer::render   qsvgrenderer.cpp     478 0x7ffff7f13957
      

      AFAIK, it's a convention in Qt to either use const references or non-const pointers to make obvious whether the parameters will be changed in the function.

      Attachments

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

        Activity

          People

            rlohning Robert Löhning
            rlohning Robert Löhning
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:

              Gerrit Reviews

                There are no open Gerrit changes