Improve dolist syntax and some PHPDocs