Instead of using stdout directly, we're now using a configurable apfl_format_writer.
Most functzions will no longer return an enum apfl_result, but will raise an error that bubbles up.