Declare variables in parameters of function literals
Differential Revision: https://phabricator.kde.org/D6272