Calling exception callback instead of directly raising exception in parser