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

QDomDocument ParseResult bool returned inconsistent with documentation

XMLWordPrintable

      In 6.5.x QDomDocument added a struct ParseResult intended to hold the parse results of calling setContent. The ParseResult explicitly converts to bool. Before the struct was created setContent returned a bool directly.

      The operator bool() function of ParseResult states it returns false if setContent does not detect an error and true if setContent does, 

      This seems inconsistent with the documentation prior to 6.5.x where setContent states it returns true if no error and false if there is an error.

      The observed behavior in 6.5.x is also at odds with the documented behavior, as successful xml file loads return true.

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

            docteam Qt Documentation Team
            kevin.zhang Kevin Zhang
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved:

                There are no open Gerrit changes