A default value of [] for a list causes IndexError.

Closes #417.