added support for outputting lists.
dropped the trim, this will be done in the individual parsers if required isntead