Foreach loops added to AutoCompletion.cpp
Simplify checkFilesystemChanges in Buffer.cpp. Also add some foreach loops to Buffer.cpp.