On Monday, 26 de September de 2011 16:02:36 Olivier Goffart wrote:
> On Monday 26 September 2011 15:40:01 Thiago Macieira wrote:
> > I know an asynchronous API is much harder to deal with and leads to more
> > complex code.
> 
> Not necessarily...
> 
> connect (manager->get(QNetworkRequest(url)), &QNetworkReply::finished,
> [=](){ QByteArray content =
> qobject_cast<QNetworkReply*>(sender())->readAll(); parse(content);
>       });
> 
> 
> 
> That is, using C++11 lambda and the proposed conneciton syntax:
> http://developer.qt.nokia.com/wiki/New_Signal_Slot_Syntax#45f5369b0d8445adba
> f54cd74a36b823

It helps, but it's still more complex than direct, unbroken synchronous code.

-- 
Thiago Macieira - thiago (AT) macieira.info - thiago (AT) kde.org
   Software Architect - Intel Open Source Technology Center
      PGP/GPG: 0x6EF45358; fingerprint:
      E067 918B B660 DBD1 105C  966C 33F5 F005 6EF4 5358

Attachment: signature.asc
Description: This is a digitally signed message part.

_______________________________________________
Qt5-feedback mailing list
[email protected]
http://lists.qt.nokia.com/mailman/listinfo/qt5-feedback

Reply via email to