Make error handling a hidden struct

THIS IS AN INCOMPATIBLE CHANGE!
Merge pull request #94 from LinuxJedi/error_functions

Make error handling a hidden struct