Skip to content

Commit 01874b2

Browse files
author
florianlink
committed
speedup of generator by factor 2
git-svn-id: http://svn.code.sf.net/p/pythonqt/code/trunk@370 ea8d5007-eb21-0410-b261-ccb3ea6e24a9
1 parent 221937d commit 01874b2

File tree

1 file changed

+7
-3
lines changed

1 file changed

+7
-3
lines changed

generator/abstractmetalang.cpp

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1091,7 +1091,8 @@ void AbstractMetaClass::addFunction(AbstractMetaFunction *function)
10911091

10921092
if (!function->isDestructor()) {
10931093
m_functions << function;
1094-
qSort(m_functions.begin(), m_functions.end(), function_sorter);
1094+
// seems like this is not needed and takes a lot of performance
1095+
//qSort(m_functions.begin(), m_functions.end(), function_sorter);
10951096
}
10961097

10971098

@@ -1840,7 +1841,10 @@ void AbstractMetaClass::fixFunctions()
18401841
(*this) -= AbstractMetaAttributes::Final;
18411842
}
18421843

1843-
foreach (AbstractMetaFunction *f1, funcs) {
1844+
// we don't care about FinalOverload for PythonQt, so we
1845+
// can remove this compare orgy...
1846+
1847+
/*foreach (AbstractMetaFunction *f1, funcs) {
18441848
foreach (AbstractMetaFunction *f2, funcs) {
18451849
if (f1 != f2) {
18461850
uint cmp = f1->compareTo(f2);
@@ -1861,7 +1865,7 @@ void AbstractMetaClass::fixFunctions()
18611865
}
18621866
}
18631867
}
1864-
}
1868+
}*/
18651869

18661870
setFunctions(funcs);
18671871
}

0 commit comments

Comments
 (0)