[Uml-devel] KDE/kdesdk/umbrello/umbrello/codegenerators
Andi Fischer
andi.fischer at hispeed.ch
Wed Jul 30 03:31:10 UTC 2008
SVN commit 839434 by fischer:
Fixing Krazy complaints about single-char QString operations for efficiency.
M +1 -1 csharp/csharpwriter.cpp
M +2 -2 ruby/rubywriter.cpp
--- trunk/KDE/kdesdk/umbrello/umbrello/codegenerators/csharp/csharpwriter.cpp #839433:839434
@@ -463,7 +463,7 @@
if (forceDoc() || !at->getDoc().isEmpty()) {
cs << m_container_indent << m_indentation << "/// <param name=\"" << cleanName(at->getName()) << "\">";
//removing newlines from parameter doc
- cs << formatDoc(at->getDoc(), "").replace("\n", " ").remove('\r').remove(QRegExp(" $"));
+ cs << formatDoc(at->getDoc(), "").replace('\n', ' ').remove('\r').remove(QRegExp(" $"));
cs << "</param>" << m_endl;
}
}
--- trunk/KDE/kdesdk/umbrello/umbrello/codegenerators/ruby/rubywriter.cpp #839433:839434
@@ -267,7 +267,7 @@
pos = re_params.indexIn(docStr, pos);
}
- docStr.replace("\n", QString("\n") + m_indentation + "# ");
+ docStr.replace('\n', QString("\n") + m_indentation + "# ");
// Write parameter documentation
foreach ( at , atl ) {
@@ -367,7 +367,7 @@
QString description = descr;
description.remove(QRegExp("m_[npb](?=[A-Z])"));
description.remove("m_");
- description.replace("\n", QString("\n") + m_indentation + "# ");
+ description.replace('\n', QString("\n") + m_indentation + "# ");
if (!description.isEmpty()) {
h << m_indentation << "# " << description << m_endl;
More information about the umbrello-devel
mailing list