diff --git a/src/tools/moc/generator.cpp b/src/tools/moc/generator.cpp index f295235c1c..75f1ce00ff 100644 --- a/src/tools/moc/generator.cpp +++ b/src/tools/moc/generator.cpp @@ -627,7 +627,7 @@ void Generator::generateCode() // Generate internal signal functions // for (int signalindex = 0; signalindex < int(cdef->signalList.size()); ++signalindex) - generateSignal(&cdef->signalList[signalindex], signalindex); + generateSignal(&cdef->signalList.at(signalindex), signalindex); // // Generate plugin meta data @@ -1408,7 +1408,7 @@ void Generator::generateStaticMetacall() fprintf(out, "}\n"); } -void Generator::generateSignal(FunctionDef *def,int index) +void Generator::generateSignal(const FunctionDef *def, int index) { if (def->wasCloned || def->isAbstract) return; diff --git a/src/tools/moc/generator.h b/src/tools/moc/generator.h index 91f8e00d61..2d4d69ca05 100644 --- a/src/tools/moc/generator.h +++ b/src/tools/moc/generator.h @@ -40,7 +40,7 @@ private: void generateProperties(); void generateMetacall(); void generateStaticMetacall(); - void generateSignal(FunctionDef *def, int index); + void generateSignal(const FunctionDef *def, int index); void generatePluginMetaData(); QMultiMap automaticPropertyMetaTypesHelper(); QMap>