I figured out the problem.
The proper syntax is indeed without the double quotes, as in:
wp_list_cats('sort_column=name&exclude=1, 2');
However, if the exclude rule results in no categories being shown, no argument is passed to the foreach()
call and therefore, it generates an error when that line interpreted (line 321 in <root>/wp-includes/template-functions-category.php
).
My suggestion is to add a note to the documentation stating this potential error.