Sze Howe Koh wrote:
> I'm curious about the rationale behind this API design. I can't think
> of any other Qt function that returns an implicitly-shared object by
> pointer, so this seems inconsistent. e.g. QWidget::font() returns a
> QFont by const-ref.

Probably because the pointer can be null. C++ does not allow null 
references. (The compiler might let you get away with it, but in principle, 
it is not allowed.)

        Kevin Kofler

_______________________________________________
Development mailing list
[email protected]
http://lists.qt-project.org/mailman/listinfo/development

Reply via email to