error messages using exceptions modifying visit pattern