fix bug in generated struct list getters