On Saturday, 24 de September de 2011 18:22:00 Peter Kuemmel wrote: > > Yes, that would be better, but it would be another generated header. The > > QObject forwarding header is just something Qt does to be nice. For other > > people who don't have syncqt, that's a new file they need to > > deal with and install. > > So sometimes the file 'QObject' is simply a copy of qobject.h? > Then this would not be possible any more.
No, today it is always a forwarding header.
My point is that syncqt is a tool we wrote for Qt. It's not used by anyone
else. Your plan was suggesting that every header processed by moc would
produce *two* headers to be installed along with the library: one containing
the output from moc and another with the forwarding.
Two aren't necessary. We only need one: the one from moc.
> > What's more, having public generated headers means we need to preprocess
> > all headers before we can start compiling.
>
> Yes compilation would slow down.
>
> > I also would like to know how moc deals with its input including headers
> > that it generated by itself.
>
> The bootsrap code can't rely on the moc's generated headers. This would
> limit the usage of Qt features for the boostrap code, or the boostrap
> code must use some pre-generated headers. Isn't it the same problem like
> the self-compiling of compilers?
That's not what I was talking about. Take the example that QIODevice derives
from QObject. In order to derive from QObject, the qiodevice.h header needs to
include the full "qobject" headers -- that includes what moc generated too. So
in order for moc to run on qiodevice.h, it needs to be run first on qobject.h.
And moc needs to understand whatever it produced too.
I don't want to shoot you down without listening to your ideas. I'd like to
give you a chance to present them and prove them. So if you feel this strongly
about the feature, go ahead and create a proof of concept.
I've only said I don't like the idea of installed generated headers,
especially if they are for almost every single class. But if the advantages
that you are proposing are worth it, we should use it.
In other words, if you want to see this, you need to create the proof of
concept, prove the 8 points I outlined in the other email and prove to us that
this is worth the hassle.
--
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
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
