fix incorrect parsing of List/Writable parsing

add unit test to prevent such mistakes from occurring again
fixes #36
fixes #37
fixes #38