This should remove runtime panics in most cases, there are a few bug! panics remaining but if they fire it's likely a logic error in mustache itself rather than a data problem and should be logged & fixed.
Issue #29 calls for returning io::Error specifically, but since a Template could invoke a closure which would need to compile the returned (String) Template there are more failure conditions than just the IO cases. It should be possible to map_err to reduce to io::Error if required.
This should remove runtime panics in most cases, there are a few
bug!
panics remaining but if they fire it's likely a logic error in mustache itself rather than a data problem and should be logged & fixed.Issue #29 calls for returning
io::Error
specifically, but since a Template could invoke a closure which would need to compile the returned (String) Template there are more failure conditions than just the IO cases. It should be possible tomap_err
to reduce toio::Error
if required.