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

QPointer : Add support for base class assignment.

    XMLWordPrintable

Details

    Description

      QPointer currently does not support assignment of a subclass to a superclass, as in the following scenario :

      struct Base : QObject {};
      struct Derived : Base {};

      QPointer<Derived> d = new Derived;
      QPointer<Base> b = d; // error: conversion from 'QPointer<Derived>' to
      non-scalar type 'QPointer<Base>' requested.

      It would be a nice feature to have.

      Attachments

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

        Activity

          People

            stormols Marius Storm-Olsen
            dettman Dean Dettman (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes