Le ven. 21 févr. 2020 à 12:29, Giuseppe D'Angelo via Development
<development@qt-project.org> a écrit :
>
> Il 21/02/20 12:15, Ville Voutilainen ha scritto:
> >> without any annotation is not what we want. We'd miss vital information 
> >> and reduce readability.
> > Can you please explain what that vital information is?
>
> That control is leaving the "local" function, and *anything* can happen
> at that point. Including fun stuff, like finding "this" to be deleted
> (pgrep for QPointer.*this in QWidget code). It's an important annotation
> for a developer IMNSHO.

Isn't that true of any function call though ? Any function could end
up deleting this, or trigerring code in another thread, or anything.
For example, a normal function call could end up emiting a signal, and
as such, any function could be as dangerous as a signal.

The other problem with emit, is that it's not required. So its absence
doesn't mean a signal is not being emitted.
_______________________________________________
Development mailing list
Development@qt-project.org
https://lists.qt-project.org/listinfo/development

Reply via email to