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

QDoc mistakes various std::chrono ymd-struct types for int

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Duplicate
    • Icon: P1: Critical P1: Critical
    • None
    • 6.4.0 FF
    • Build tools: qdoc
    • None
    • All

      The documentation of QDate opens its list of constructors with

       QDate(int ymd) 

      which was something of a surprise to me, as there is no such constructor (nor is it clear how one int would encode year, month and day).
      Following the link, it turns out to be referring to

      template <typename> QDate::QDate(int ymd)
      template <typename> QDate::QDate(int ymd)
      template <typename> QDate::QDate(int ymd)
      template <typename> QDate::QDate(int ymd)
      

      (all tagged as [since 6.4]), none of which in fact exist.
      My best guess is that these are generated somehow from

          \fn QDate::QDate(std::chrono::year_month_day ymd)
          \fn QDate::QDate(std::chrono::year_month_day_last ymd)
          \fn QDate::QDate(std::chrono::year_month_weekday ymd)
          \fn QDate::QDate(std::chrono::year_month_weekday_last ymd)
      

      However, replacing the struct types of these actual parameters with int is unequivocally A Bug, presumably in QDoc.

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

            docinfrastructure Documentation Infrastructure Team
            Eddy Edward Welbourne
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved:

                There are no open Gerrit changes