[Development] A modest proposal: disable lower-case keywords (emit, foreach, forever, signals, slots) by default

Ville Voutilainen ville.voutilainen at gmail.com
Fri Feb 21 14:00:53 CET 2020


On Fri, 21 Feb 2020 at 14:58, Sérgio Martins <sergio.martins at kdab.com> wrote:
> > Why do I need to know that it's a signal being emitted? How is that
> > "vital information"? I could just as well
> > invoke any other callback, but I find myself not exactly yearning for
> > being able to write
> > callback somethingHappened();
>
>
> Signals have different semantics than regular functions.

In what way?

> If I'm reading the body of makePlane() I can ignore the signal
> emissions, as they aren't important for how a plane is made, they just
> inform whoever is listening.

That doesn't seem to be correct in general. Some signals absolutely
must be emitted
for clients to work correctly.

> And I'd argue that the emitter shouldn't even know who or how many slots
> are connected to the signal, might even be zero, it shouldn't matter.

..and? What does that have to do with whether you do or do you emit?


More information about the Development mailing list