Added header for error checking

Added a header for error checking and applied error checking to meld
inputs, boolean inputs, and machi. Todo: apply for all pair inputs and
possibly integer inputs (if actually possible).