| 38 | } |
| 39 | |
| 40 | void NodeJS::initialize(DeclarationBuilder* builder) |
| 41 | { |
| 42 | QMutexLocker lock(&m_mutex); |
| 43 | |
| 44 | // Create "module", a structure that may contain "exports" if the module |
| 45 | // refers to module.exports |
| 46 | createObject(QStringLiteral("module"), 1, builder); |
| 47 | |
| 48 | // Create "exports", that can also contain the exported symbols of the module |
| 49 | createObject(QStringLiteral("exports"), 2, builder); |
| 50 | } |
| 51 | |
| 52 | void NodeJS::createObject(const QString& name, int index, DeclarationBuilder* builder) |
| 53 | { |
no outgoing calls