2 ms·
The C++ that you write does not run through moc. It uses a few special macros, each of which either inserts something trivial (e.g. a virtual method declaration
by ahartmetz 9y ago
The C++ that you write does not run through moc. It uses a few special macros, each of which either inserts something trivial (e.g. a virtual method declaration for Q_OBJECT) or nothing at all (e.g. "emit"). In another build step, moc scans for those macros and generates additional code accordingly. The features added by that generated code are super useful and are implemented in separate methods, i.e. code that does not somehow appear in the middle of your own.