This is a bunch of stuff I worked on last night

This was all for making it possible to return an error from
compare/locate. There may have been more, but I can;t recall right now.