This is an automatically generated e-mail. To reply, visit:

On November 9th, 2013, 2:05 p.m. UTC, Michel Ludwig wrote:

src/utilities.cpp (Diff revision 1)
QString KileUtilities::lastModifiedFile(const QStringList& files, const QString& baseDir)
Hehe, this is a nice example of how to use encapsulated algorithms, but I'm afraid it makes the code almost unreadable...

Would you mind changing it a bit so that it becomes easier to understand again?

On November 11th, 2013, 11:15 a.m. UTC, Eugene Shalygin wrote:

I'm afraid that I'm not sure that understand you correctly. Do you want to avoid usage of the <algorithm> and replace it with, say, Q_FOREACH and a couple of local variables? I thought that <algorithm> makes code more readable, since everybody knows what functions from it do, and small predicate classes are really easy to understand.

Therefore I'm not sure and thus could you, pleaas, confirm?
Yes, exactly. I think the use of max_element can be justified but this line almost gives me a headache ;)

std::transform(files.begin(), files.end(), std::back_inserter(absoluteFileNames), FilePathConcatenate(baseDir));

Questions that spring to my mind are: What does 'transform' do? What is a 'back_inserter'? What does 'FilePathConcatenate' do?
I think the loop that was there previously was slightly easier to understand :)

- Michel

On October 8th, 2013, 12:58 a.m. UTC, Eugene Shalygin wrote:

Review request for Kile and Michel Ludwig.
By Eugene Shalygin.

Updated Oct. 8, 2013, 12:58 a.m.

Repository: kile


Kind of addition to

This patch takes part of Info::lastModifiedFile() that works with file list, and splits it into  free function. The last one is called from Info::lastModifiedFile() and from LaTeX::updateBibs().
This allows updateBibs(true) to avoid implicit check of the master document.

Michel, seem like I forgot to add you to reviewers one year ago and you missed this review request. It is exceptional useful for LivePreview. Everytime I see my wife spending twice the time I do in waiting for LivePreview results, I recall this patch :)


  • src/documentinfo.cpp (efdacdf)
  • src/utilities.h (afb3af2)
  • src/utilities.cpp (9b73e6b)

View Diff